- Upvotes Received
- 3
- Posts with Upvotes
- 2
- Upvoting Members
- 2
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
3 Posted Topics
your code: " printf("the clock speed: %f",start-end); " Hey dude, change to: [B]end - start[/B] to obtain time in miliseconds or [B](end - start) / 1000.0[/B] for time in seconds.miliseconds (and don't forget to declare [B]double[/B] start, end; ) ;)
[B]fseek()[/B] and [B]ftell()[/B] work only for files < 2,147,483,647 bytes [B]fseeko64()[/B] and [B]ftello64()[/B] from [B]<stdio.h>[/B] can deal with files up to 18,446,744,073,709,552,000 bytes the printf format for unsigned long long val is [B]%I64d[/B] eg. Obtaining the file dimension (this code was tested with [B]GNU GCC compiler[/B] (MinGW/Cygwin) from code::blocks)
unsigned char string[]; ///////// Convert entire string: uppercase to lowercase //////// for (i=0; i<strlen(string); i++) if (isupper(string[i])) string[i]=tolower(string[i]); ///////// Convert entire string: lowercase to uppercase //////// for (i=0; i<strlen(string); i++) if (islower(string[i])) string[i]=toupper(string[i]);
The End.
AuSsIeStOnE