The thermal efficiency of an engine is
[tex]\eta= \frac{W}{Q} [/tex]
where
W is the work done by the engine
Q is the heat absorbed by the engine to do the work
In this problem, the work done by the engine is W=200 J, while the heat exhausted is Q=600 J, so the efficiency of the machine is
[tex]\eta= \frac{W}{Q}= \frac{200 J}{600 J}=0.33 = 33 \% [/tex]