Skip to content
Related Articles

Related Articles

Python Program to Convert Celsius To Fahrenheit
  • Last Updated : 29 Aug, 2020

Given the temperature in degree Celsius. the task is to convert the value in the Fahrenheit scale and display it.

Examples :

Input :
Output :
37.00 Celsius is: 98.60 Fahrenheit

Input :
Output :
40.00 Celsius is equivalent to: 104.00 Fahrenheit

Take Celsius temperature as input from the user, apply the conversion formula of Fahrenheit from Celsius, and display it. The relationship between the Celsius scale and the Fahrenheit scale is given by :
 fahrenheit = (celsius*1.8) + 32
Below is the implementation.

# Temprature in celsius degree
celsius = 40
# Converting the temprature to 
# fehrenheit using the above
# mentioned formula
fahrenheit = (celsius * 1.8) + 32
# printing the result
print('%.2f Celsius is equivalent to: %.2f Fahrenheit'
      %(celsius, fahrenheit))


40.00 Celsius is equivalent to: 104.00 Fahrenheit

 Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.  

To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course

My Personal Notes arrow_drop_up
Recommended Articles
Page :