Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
C Programming
SIze of file
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Lew Pitcher, post: 2424532"] -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 #include <stdio.h> { FILE *fp; unsigned long count; if ((fp = fopen("the file","r")) != NULL) /* fopen() the file */ { count = 0; /* initialize count to 0 */ while (fgetc(fp) != EOF) ++count; /* until fgetc returns EOF, */ /* add 1 to the counter */ fclose(fp); /* fclose() the file */ } } - -- Lew Pitcher Master Codewright & JOAT-in-training | GPG public key available on request Registered Linux User #112576 ([URL]http://counter.li.org/[/URL]) Slackware - Because I know what I'm doing. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.7 (GNU/Linux) iD8DBQFDATBHagVFX4UWr64RAiMbAJwIvzeLCG9TIzhbfLXnHzMMe2cOUgCeOxo6 lk0pGN1IBXNA0S35eIcLGp8= =d4q5 -----END PGP SIGNATURE----- [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
C Programming
SIze of file
Top