Hungarian Notation

Hungarian Notation is a variable-naming convention so called in the honor of the legendary Microsoft programmer Charles Simonyi. According to this convention the variable name begins with a lower case letter or letters that denotes the data type of the variable. For example, the sz prefix in szCmdLine stands for ‘string terminated by zero’; the … Read more

ftell() | fseek() in C

ftell() function c Functions ftell() and fseek() are important in a program performing file manipulations. Function ftell() returns the current position of the file pointer in a stream. The return value is 0 or a positive integer indicating the byte offset from the beginning of an open file. A return value of -1 indicates an … Read more

fread() and fwrite() in C

The functions fread() and fwrite() are a somwhat complex file handling functions used for reading or writing chunks of data containing NULL characters (‘\0’) terminating strings The function prototype of fread() and fwrite() is size_t fread(void *ptr, size_t sz, size_t n, FILE *fp)size_t fwrite(const void *ptr, size_t sz, size_t n, FILE *fp); Example of fread() … Read more