up previous next
Counts cpu time
This function returns a
whose value is the user CPU usage in
seconds since the start of the program: this is the amount of time the
processor has dedicated to your computation, and may be rather less than
the real elapsed time if the computer is also busy with other tasks.
The most common usage is with
as shown in the example.
/**/ StartTime := CpuTime(); -- time in seconds since the start (a RAT)
/**/ -- .... long computation ....
/**/ PrintLn "Computation time: ", TimeFrom(StartTime);
You can use
to see the value of
in a more easily