A two-level quantum system with gap ω works as a heat engine. The Otto cycle: (1) isentropic compression ω_cold→ω_hot, (2) hot thermalization, (3) isentropic expansion ω_hot→ω_cold, (4) cold thermalization. Work extracted when η<1−ω_cold/ω_hot.