First, let's remember the concepts of spontaneous and nonspontaneous reaction:
A spontaneous reaction is a reaction that favors the formation of products at the conditions under which the reaction is occurring. This would be called an exothermic reaction, it releases energy.
A nonspontaneous reaction is a reaction that does not favor the formation of products at the given set of conditions. In order for a reaction to be nonspontaneous, it must be endothermic, accompanied by a decrease in entropy, or both.
In this case, when the reaction takes place, the temperature of the system increases which means that heat is released and heat is a form of energy. Energy is released.
The answer based on this logic would be D.