Courses
Tutorials
Interview Prep
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
Similar Topics
Web Technologies
32.1K+ articles
DSA
20.5K+ articles
Misc
7.7K+ articles
C++
3.8K+ articles
C Language
1.3K+ articles
C Programs
441+ articles
CPP-Library
254+ articles
C-Functions
90+ articles
cpp-file-handling
57+ articles
File Handling
24+ articles
C-File Handling
44 posts
Recent Articles
C Miscellaneous Interview Questions
Last Updated: 15 November 2025
C programming isn't just about printf() and for loops. For technical interviews, especially in system-level, embedded, or product-based roles, you're expected to master th...
read more
AdvanceC
C-File Handling
recursive-approach
Interview Prep
perror() in C
Last Updated: 27 July 2026
The perror() function is a built-in C function used to print a custom error message followed by the system-generated error description based on the value of the global err...
read more
C Language
C-Functions
C-File Handling
rewind() in C
Last Updated: 21 July 2026
The rewind() function is a standard library function declared in the stdio.h header file. It is used to move the file position indicator back to the beginning of a file wi...
read more
C Language
C-Functions
C-File Handling
fwrite() in C
Last Updated: 23 July 2026
fwrite() is a standard library function used to write a block of data from memory to a file. It is mainly used for writing binary data, such as arrays and structures, dire...
read more
C Language
C-Functions
C-File Handling
fclose() Function in C
Last Updated: 22 July 2026
The fclose() function is a standard library function declared in the stdio.h header file. It is used to close a file that was previously opened using fopen() or related fi...
read more
C Language
C-Functions
C-File Handling
How to Read Input Until EOF in C?
Last Updated: 23 July 2025
In C, reading input until the End of the File (EOF) involves reading input until it reaches the end i.e. end of file. In this article, we will learn various methods throug...
read more
C Programs
C Language
Picked
c-input-output
C-File Handling
C Examples
How to Read From a File in C?
Last Updated: 17 June 2024
File handing in C is the process in which we create, open, read, write, and close operations on a file. C language provides different functions such as fopen(), fwrite(), ...
read more
C Programs
C Language
Picked
C-File Handling
C Examples
How to Read a File Line by Line in C?
Last Updated: 29 May 2025
In C, reading a file line by line is a process that involves opening the file, reading its contents line by line until the end of the file is reached, processing each line...
read more
C Programs
C Language
Picked
C-File Handling
C File Handling Programs
C Examples
How to Write a Struct to a Binary File in C?
Last Updated: 23 July 2025
C file handling allows users to store the data from a C program to a file in either the text or the binary format. In this article, we will learn how to write a struct to ...
read more
C Programs
C Language
Picked
C-Structure & Union
C-File Handling
C Examples
How to Read a Struct from a Binary File in C?
Last Updated: 23 July 2025
The structure in C allows the users to create user-defined data types that can be used to group data items of different types into a single unit. We can save this structur...
read more
C Programs
C Language
Picked
C-Structure & Union
C-File Handling
C Examples
C File Handling Programs
Last Updated: 23 July 2025
C Program to list all files and sub-directories in a directoryC Program to count number of lines in a fileC Program to print contents of fileC Program to copy contents of ...
read more
C Programs
C Language
C-File Handling
C File Handling Programs
C Program to Read Content of a File
Last Updated: 24 July 2026
Reading a file in C involves opening the file, retrieving its contents, and closing it after use. The C Standard Library provides several functions for reading files depen...
read more
C Programs
C Language
C-File Handling
Opening Modes in Standard I/O in C/C++ with Examples
Last Updated: 23 July 2025
Pre-requisites: File Handling in C++So far the operations using the C program are done on a prompt/terminal that is not stored anywhere. But in the software industry, most...
read more
C++
cpp-file-handling
C-File Handling
How to create Binary File from the existing Text File?
Last Updated: 23 July 2025
In this article, we will discuss how to create a binary file from the given text file. Before proceeding to the steps, let's have an introduction of what are text files an...
read more
C++ Programs
C++
C-File Handling
File Handling
C program to read a range of bytes from file and print it to console
Last Updated: 06 August 2025
Given a file F, the task is to write C program to print any range of bytes from the given file and print it to a console.Functions Used:fopen(): Creation of a new file. Th...
read more
C Programs
C Language
C-File Handling
File Handling
1
2
3