Thermodynamics

A proposed cyclic machine produces 500 J of work while receiving no energy input and rejecting no energy. Which principle rules it out?