In addition to Stoned_Coder's comment, you're not able to any other processing during the sleep period either. It takes control of the program thread and doesn't return control until at least the amount of time passed. You could mulithread the app but I'm going to guess that's beyond your ability.

I'd suggest using the clock() function. It returns the approximate time that the program has being running. Divide the result by CLOCKS_PER_SEC to get the number of seconds the program has been running. It has nothing to do with the current time on your system so you can make a pseudo clock with it. Maybe that will be acceptable.