daily pastebin goal


a guest Aug 12th, 2017 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Your code here...
  2. def ctof(celcius):
  3.     return celcius * 1.8 + 32
  4. def ftoc(fahrenheit):
  5.     return (fahrenheit -32) / 1.8
  6. try:
  7.     print ctof(float(input("Enter a number to convert to fahrenheit from celcius: ")))
  8.     print ftoc(float(input("Enter a number to convert to celcius from fahrenheit: ")))
  9. except ValueError:
  10.     print "Sorry! You need to enter a NUMBER!"
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand