Engine failures are quite rare, but they do happen. I think the statistic is something like one for a pilot's entire career...and that's probably based on the reliability of engines from 20 years ago.
All airliners, no matter how many engines they have, can suffer an engine failure on takeoff, and if above V1 (a speed that is calculated for every takeoff), will be able to continue the takeoff, and fly away. If there is high terrain in the area, that will be accounted for in the calculations. Below V1, all will stop on the black stuff.
Airborne, the loss of an engine is less of a hassle in a 4 engined aircraft, but it isn't all that dramatic in a twin either. A quad will have to descend but not as far as a twin. In both cases they'll continue to fly perfectly well (and again, high terrain is accounted for in route planning).
Loss of an engine will reduce the range of a twin by about 30%, and a quad by 10-15%. A twin will not be allowed to fly past an acceptable airport with an engine shut down, though it may be acceptable to do so in a quad. As a general rule, if within approximately 2,000 miles of destination, a quad will be able to continue with one shut down.
Engine failures in the cruise are exceptionally rare.
Loss of all engines...the anti gravity systems look after that. Seriously...the aircraft remains totally controllable, and you have about 20 minutes to get one or more going again.