The air that comes out of the exhaust hose is very hot. If you don’t vent that hot air out of the room through a window, it will be impossible for the air conditioner to lower the temperature of the room.