C - fprintf
File Operations in Tamil
Learn C - C tutorial - C fprintf - C examples - C programs
C - fprintf() - Definition and Usage
- In C – Programming, the fprintf function is used to pass the argument according to the specified format in terms of the file indicated format.
C Syntax
Sample - C Code
C Code - Explanation :
- Here in this statement we create a file pointer “fp”.
- Here in this statement we open the text file using “fopen” function in writing mode.
- In this statement we write the content in the text file using fprintf function.
Sample Output - Programming Examples
- Here in this output, the entered statement “Welcome To Wikitechy” from the program using fprintf function were written in the sample.txt file which will be stored in the BIN folder of C .
Example
Output
Learn C - C tutorial - C fprintf - C examples - C programs