I saw a BeOS demo of turning off processors. The GUI allowed you to uncheck all the processor checkboxes and the machine goes dead. :)
int32 is_computer_on(); //Returns 1 if the computer is on. If the computer isn't on, the value returned by this function is undefined.
double is_computer_on_fire(); //Returns the temperature of the motherboard if the computer is currently on fire. If the computer isn't on fire, the function returns some other value.