We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6bf3dca commit ff16a89Copy full SHA for ff16a89
conversions/fahrenheit_to_celsius.py
@@ -28,10 +28,7 @@ def fahrenheit_to_celsius(fahrenheit):
28
"""
29
raise TypeError("'str' object cannot be interpreted as integer")
30
31
- celsius = (fahrenheit - 32) * 5 / 9 # value converted from fahrenheit to celsius
32
- celsius = round(celsius, 2)
33
- # converted (celsius) value is rounded to two decimal places
34
- print(celsius)
+ return round((fahrenheit - 32) * 5 / 9, 2)
35
36
37
if __name__ == "__main__":
0 commit comments