os.clock

From ComputerCraft
Jump to: navigation, search

os.clock
Function
Syntax
os.clock()
Returns number
API os
Source CC:Tweaked (source)

Returns the time since the Computer was booted in seconds.

ExampleExampleGet the running Time
Print the time since the Computer is running in seconds.
Code
print("The Computer is running since "..os.clock().." seconds")
Output
The Computer is running since 10 seconds