home

Scientific Computing (Psychology 9040a)

Fall, 2021

Temperature Converter: sample solution


C = input('enter the temperature in Celsius: ');
F = (9/5)*C + 32;
fprintf('%.1f degrees Celsius is %.1f degrees Fahrenheit\n', C, F);