There are two issues with power supply. One is the matter of power smoothing, preventing sudden surges or drops in supply, and the other is supply itself. Blackouts and brownouts can cause the computers to shut down suddenly, losing any information stored only in short-term memory (RAM). Sudden surges or drops in supply can cause physical damage to computer components, if they are bad enough.
Power smoothing is only needed in some areas. Local computer experts will be able to tell you if your area's supply is prone to surges and dips, and can offer advice on whether you need surge protectors or power smoothers. However, if you buy a UPS (uninterruptible power supply), most have power smoothing built in.
A UPS (uninterruptible power supply) is used to protect against sudden loss of power. It's somewhat of a misnomer, as it doesn't itself provide power - it is essentially a large battery that charges itself from the power main. The computers are plugged into the UPS, and if the mains power cuts out, the UPS provides enough power for the computers to shut themselves down and save all their information.
Most UPSes will signal the computer when the main power cuts out. Get your local computer expert to ensure that yours does (preferably before you buy it), and ensure that your computer is set up to respond to that signal.
If you want a truly uninterruptible supply, there are companies in existence which would be happy to sell you a power generator that cuts in automatically when mains power cuts out, and a UPS-like device to handle the cutover to the generator.