Skip to content

Instantly share code, notes, and snippets.

@Tricky1975
Created October 12, 2017 06:40
Show Gist options
  • Save Tricky1975/e2108f067a050e2e728c230cb00aba24 to your computer and use it in GitHub Desktop.
Save Tricky1975/e2108f067a050e2e728c230cb00aba24 to your computer and use it in GitHub Desktop.
Simple script to convert Celcius to Temperatoera and vice vera (Phantasar Chronicles)
#!/usr/bin/python
print "1 = Celcius >> Temperatoera"
print "2 = Temperatoera >> Celcius"
a = None
while (a!="1" and a!="2"): a = raw_input("Enter calculation value: ")
t = raw_input("Temperature: ")
if a=="1":
celcius = float(t)
temperatoera = (celcius/37)*100
elif a=="2":
temperatoera = float(t)
celcius = (temperatoera/100)*37
else:
print "Sorry, unknown calculation request"
quit()
print "Celcius: %i"%celcius
print "Temperatoera: %i"%temperatoera
@Tricky1975
Copy link
Author

A few notes:

  • This script has been written for Python 2.7 and it surely won’t work in Python 3.x
  • Temperatoera is a female Befindo scientist who in the Phantasar universe invented the scale in which most people on Phantasar measure temperatures.
  • The Phantasar Chronices

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment