Using time.h when I code something like this,
I get an integer, such as something that takes 1.23 seconds would be listed as 1 second. is there something Im doing wrong or a more accurate function I should be using?Code:#include <iostream>
#include <time.h>
#include <system.h>
int main()
{
float dif = 0;
time_t start, end;
time(&start);
//mmmm... function...
time(&end);
dif = difftime(end,start);
std::cout << dif;
system("pause");
return 0;
}