CodeSteps

Python, C, C++, C#, PowerShell, Android, Visual C++, Java ...

C Programming

C Programming

C Programming – Dealing with files using un-buffered functions

As part of this series of articles, we are discussing buffered and un-buffered functions dealing with file management. We already discussed buffered functions in our previous articles and started discussing un-buffered functions. We have seen open and close functions in the previous article. In this article, we will discuss a few more un-buffered file management […]

C Programming – How to use bit fields in structures?

Structures in C are used to group multiple variables of the same or different types. The variables inside the structures can be accessed through its structure variables. I recommend you to read the article, “C Programming – Understanding Structures in C“, before proceeding with this. Usually, ‘C’ structures are to group related information. ‘C’ compiler […]

C Programming – Dealing with files – How to use open function to open a file?

We have discussed that ‘C’ provides buffered and un-buffered functions for file management. We have already discussed some of the buffered functions in our previous articles; “C Programming – Dealing with files – How to read from a file?“, “C Programming – Dealing with files – How to write to the file?” and “C Programming – Dealing […]

C Programming – Dealing with files – How to fetch a record from the file?

In our previous article, we have used “getrecord” function. We will start this article with this function. We have to implement “getrecord” to fetch a record from the “employee.dat” file. It will check the “employee.dat” file for an employee record based on the given employee number. If it finds the employee record it will return […]

C Programming – Dealing with files – How to read from a file?

C library provides a good number of file handling functions to deal with files and directories/folders. Generally, we can classify these functions as: Buffered functions and Un-buffered functions. Un-buffered functions are the raw functions that deal directly with storage devices. Whereas, buffered functions maintain memory buffers to improve the performance and reduce the number of […]

Scroll to top