Can someone tell me what's wrong with this program?
-------- cut here -----------
import sys
def temp_converter_2(degree):
print("Do you want to convert to Celsius or Fahrenheit? Enter C or F")
answer = str(sys.stdin.readline())
if answer == "C":
converted_value = (degree - 32) * 5/9
elif answer == "F":
converted_value = (degree * 9/5) + 32
else:
print("That's not C or F")
converted_value = -99;
print(converted_value)
def __main__():
print("Enter temp to convert:")
temp = int(sys.stdin.readline())
temp_converter_2(temp)
------- cut here --------
When I run it, I get nothing. I am hoping that it will ask me for input. What am I missing?
MacBook-Pro-(9):stuff$ python temp_converter_2.py MacBook-Pro-(9):stuff$