Two students are discussing how programmable thermostats work. Student A says that a piece of material within the thermostat changes length depending on moisture content of the air and that temperature is related to this change in moisture. Student B says that there's a material within the thermostat that changes its length based on temperature and that the measured temperature is related to the change in length. Which of the following statements is correct?