Question: I'm using clock(), and I'm wondering whether it ever resets or maxes out. all I'm using it for is just too subject it from a previous function call and find the difference.

Thanks for the help so far but I'm not really able to get the chrono thing working in VS '12 but its fine because I think its a little more than I need anyway, I was think about using 's time() but I have no idea how to convert the t\_time into an int that contains just the current seconds 0-60, any help?

Answer: 
As far as the standard is concerned, 

> 
> The range and precision of times representable in `clock_t` and `time_t` are implementation-defined.
> 
> 
> 

(C99, §7.23.1 ¶4)

so there are no guarantees of range; the definition of `clock()` does not say anything about wrapping around, although it says that 

> 
> If the processor time used is not available or its value cannot be represented, the function returns the value `(clock_t)(-1)`
> 
> 
> 

So we may say that exceeding the range of `clock_t` may be seen as "its value cannot be represented"; on the other hand, this interpretation would mean that, after some time, `clock()` becomes completely useless.

In facts, if we get down to a specific implementation (glibc), we see:

```
matteo@teokubuntu:~$ man 3 clock

```

> 
> 
> ```
>    Note that  the  time  can  wrap  around.   On  a  32-bit  system  where
>    CLOCKS_PER_SEC  equals 1000000 this function will return the same value
>    approximately every 72 minutes.
> 
> ```
> 
>
The simple answer is that if you're just using it to time a function, it will probably not wrap around. It may also be too slow and chances are you might see a function duration of zero. If you want accurate timing for a function that executes fast, you're probably better using an OS level call like [this one on Windows](https://stackoverflow.com/questions/1825720/c-high-precision-time-measurement-in-windows).