When the gas in the cylinder of an internal combustion engine has more internal energy: a) at the beginning or at the end

When the gas in the cylinder of an internal combustion engine has more internal energy: a) at the beginning or at the end of the working stroke; b) at the end of the suction stroke or at the end of the compression stroke?

a) at the beginning of the working stroke. because then the gas expands, and part of its internal energy goes into mechanical.
b) at the end of the compression stroke, because during compression the internal energy of the gas increases.

Remember: The process of learning a person lasts a lifetime. The value of the same knowledge for different people may be different, it is determined by their individual characteristics and needs. Therefore, knowledge is always needed at any age and position.