The CLOCKS_PER_SEC macro yields the precision of the value returned
by the clock() function. It doesn't *necessarily* correspond to
any physical characteristic of the system. An imaginary example:
if CLOCKS_PER_SEC is one million (as it is on POSIX systems),
the value returned by clock() represents a number of microseconds,
but it might always be a multiple of 1000, indicating an underlying
resolution of 1 millisecond.
As James Kuyper points out, the standard's definition of
CLOCKS_PER_SEC allows it to vary (though presumably it would keep the
same value for a run of a program), but on many (most?) systems it's
defined as a constant. In fact, I'd be at least mildly surprised
if there were a system with CLOCKS_PER_SEC not defined as a constant.
--
Keith Thompson (The_Other_Keith)
ks...@mib.org <
http://www.ghoti.net/~kst>
Will write code for food.
void Void(void) { Void(); } /* The recursive call of the void */