Cannabis is a very hardy plant and can survive cold and heat well. Just like you or me though, it can get stressed and not function well in the extremes. Cannabis can freeze or boil to death. It can stop growing or go into stasis. It will go into survival mode if the temperatures are too high or too cold for too long. Twenty-seven degrees centigrade is the accepted ideal for vigorous cannabis growth. Indoors this is easy to achieve with fans, air conditioning units, heating and cooling mats. Lights will certainly generate heat that needs to be vented.