Tag Archives: syntax

Explanation of FUNCTION: A function is a block of code that has a name and it has a property that it is reusable i.e. it can be executed from as many different points in a C Program as required. Function groups a number of program statements into a unit and gives it a name. This… Read More »

Write the syntax and explain the purpose of the following function: 2m Dec2005 (iii) Fprintf( ) Description The C library function int fprintf(FILE *stream, const char *format, …) sends formatted output to a stream. Declaration Following is the declaration for fprintf() function. Parameters stream — This is the pointer to a FILE object that identifies… Read More »

Write the syntax and explain the purpose of the following functions : 2m Dec2005 (ii) Fclose( ) Description The C library function int fclose(FILE *stream) closes the stream. All buffers are flushed. Declaration Following is the declaration for fclose() function. Parameters stream — This is the pointer to a FILE object that specifies the stream… Read More »

Write the syntax and explain the purpose of the following functions : 2m Dec2005 (i) Fseek( ) Description The C library function int fseek(FILE *stream, long int offset, int whence) sets the file position of the stream to the given offset. Declaration Following is the declaration for fseek() function. Parameters stream — This is the… Read More »