20 points + Brainliest. Please help!

A piston consists of a closed cylinder with a moveable top. When a chemical reaction heats the gas inside the piston, the gas expands and lifts the top. For the thermodynamic system of the piston, are the values of heat Q and work W positive, zero, or negative?

A. Both Q and W are positive
B. Q is positive, W is negative
C. Both Q and W are negative
D. Q is positive, W is zero