Program gifted children choreography. Development of children's creative talent in choreography in preparation for competitions. Diagnostic tasks. Artistry
Read also
Standard POSIX has its own method to get the file size.
Include the sys/stat.h header to use the feature.
abstract
- Get file statistics using stat(3) .
- Get the st_size property.
Examples
Note. Size is limited to 4GB. If not Fat32 system Fat32 then use the 64-bit version!
#include
ANSI C (standard)
ANSI C does not provide a direct way to determine the length of a file.
We will have to use our minds. We will now use the search approach!
abstract
- Find the file to the end using fseek(3) .
- Get the current position using ftell(3) .
example
#includeIf the stdin file or pipe. POSIX, ANSI C will not work.
Will return 0 if the file is a pipe or standard stdin.Opinion: You should use standard instead POSIX. Because it has 64 bit support.