The lack of an atmosphere means convection cannot happen on the moon. Therefore, there is no form of heat dissipation on regions in direct sunlight. In addition, the lack of an atmosphere means there is no greenhouse effect on the moon. This is why regions facing away from sunlight are very cold.