QUOTE(jjhaag @ 5 Jan, 2008 - 05:07 PM)

Tom9729 is right about ctime - that's basically just a formatting function, not a timer.
I agree that you'd be better off using a more precise timer - for instance, clock() instead of time(), because of the added precision it gives you.
Thank you, Tom and JJ for your help. There are just so many different classes available in the STL, and I haven't learned many of them yet. I was able to get the time functions to work, but as you both have said, I may be better off using the timer. However, I have another question... is it possible to find out how many milliseconds have passed? The largest amount of time it takes for a full insertion sort to work on 100,000 integers was only about 31 seconds.. so I think I need more precision for the assignment. (The assignment is to create a chart that shows the results of writing the hybrid sort, and changing the minimum number for it to go into the insertion sort. Obviously, it's difficult to notice much of a difference when the longest time is only 31 seconds.
EDIT: Well, the two of you pointed me in the right direction, because I just did a search here in the C++ forum on 'millisecond', and found a thread from someone who appears to have had a similar assignment. born2c0de had brought up another function, GetTickCount, which is part of the windows.h class, and that actually returns the milliseconds for me. Perfect! Thank you again for all your help, and for leading me the right way.
This post has been edited by dmd1120: 5 Jan, 2008 - 04:44 PM