I tried to program the Timer class (not suspecting that boost was one), and then when this did not work, I tried to simply output the clock () value using this code:
#include <ctime>
#include <iostream>
int main()
{
for(int i = 0; i < 50; ++i)
{
std::cout << std::clock() << " ";
}
return 0;
}
When I run the program, I get a series of 0. I have a similar experience in using the functions of a sleeping thread in a thread to stretch the time longer (although after a few seconds it jumps from 0 to 10,000 and continues to output 10,000).
I am running Gentoo Linux. Is this a platform? C ++ thing? What's happening?
: , 10000 , . , , 10000. , . , , ()? ( , , ?)