The air conditioner
Air conditioner work by using ‘evaporative heat'(a phenomenon that absorbs the surrounding heat when the liquid evaporates).
The indoor unit suddenly expands the compressed refrigerant through a narrow hole. Then, the refrigerant evaporates into the gas and absorbs the surrounding heat.
The vaporized refrigerant compresses in the outdoor unit to make a liquid. Because the condensed liquid has a high temperature, it exhausts heat to the outside through a fan.
Therefore, the air conditioner only moves the heat energy from the indoor unit to the outdoor unit. It cannot disappear the heat energy.
Rather, the air conditioner consumes additional electrical energy to operate the compressor. Therefore, it is a heating device.