Re: c help
The best way to time a running program is to instrument it internally. What platform are you running on DOS, Win, Linux????. How accurate do you want to time and how short is the expected running time?
Some techniques to think of:
Wrap the program up as a function and call from a shell program that times the execution of the function.
Use hardware timers - if a simple embedded app, flip an output bit at the start and stop and use an external timer to time the duration.
Be aware of many hidden time components such as the OS. In a complex system such as Win or Linux, the OS will interrupt this may or may not be desired.
If you just want a rough time - use a stop watch.
There are many ways to go - you must supply more details to allow us to narrow the options.
Swingbyte