# Program to convert degrees Celsius to degrees Fahrenheit # Matt Bishop, July 11, 2012 # for COSMOS 2012, Cluster 4 def tempcvt(): # read temperature to convert try: ctemp = float(input("Enter degrees in Celsius: ")) except EOFError: return except TypeError: print("I need a number -- please try again!") return # convert it ftemp = 9.0 / 5.0 * ctemp + 32 # print out converted temperature print(ctemp, "degrees Celsius is", ftemp, "degrees Fahrenheit") # # run the program # tempcvt()