Dear, thanks for the reply. I tried using your suggestions and find the min max and so on
I get a vector subscripts out of range error.
And when I try to output whats inside the vector msec_intervals it prints out 0 as there none in it.
My implementation is:
Do not try to iterate beyond msec_intervals.size() - 1
for( std::size_t i = 0 ; i < msec_intervals.size() ; ++i ) { /* ... */ }
> And when I try to output whats inside the vector msec_intervals it prints out 0
It will print out zero if the function you are trying to time finishes executing before the clock ticks. (the clock ticks approximately CLOCKS_PER_SEC times every second).
Thanks for the reply. I followed the links and I like what you did but because I'm using basic c++ compiler that last line that prints out the std interval gives me an error for the auto identifier.
Can that be fixed by something else? But other than that it works fine. I can't get the min ad Max unless I know what's inside the vector