Update 1.py

This commit is contained in:
Lukas Baumann 2021-02-17 11:45:48 +01:00 committed by GitHub
parent 4e1f0f6ef0
commit f4f52d9441
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,7 +1,6 @@
temp = input()
if "C" in temp:
temp = float (temp[:-1])
print(temp*9/5+32, "F", sep="")
temp_num = float (temp[:-1])
if "C" == temp[-1]:
print(temp_num*9/5+32, "F", sep="")
else:
temp = float (temp[:-1])
print((temp-32)*5/9, "C", sep="")
print((temp_num-32)*5/9, "C", sep="")