More

# Python Program to Convert Celsius to Fahrenheit

When it comes to converting Celsius to Fahrenheit, it is really quite simple. All you need to do is multiply the Celsius temperature by 9/5 and add 32. This will give you the equivalent Fahrenheit temperature.

For example, if the temperature outside is 10 degrees Celsius, then the equivalent Fahrenheit temperature would be 50 degrees (10 x 9/5) + 32 = 50.

Table of Contents

## Program Code

``````celsius = float(input("Enter the temperature in celsius: "))
fahrenheit = (celsius * 9/5) + 32
print("The temperature in fahrenheit is: ", fahrenheit)``````

Input Given:

`Enter the temperature in celsius: 30`

Expected Output:

`The temperature in fahrenheit is: 86.0`

## Code Explanation

1. The user is asked to enter the temperature in Celsius.
2. The input is stored in the variable celsius.
3. The value of celsius is converted to a float.
4. The value of celsius is multiplied by 9/5 and 32 is added to it.
5. The result is stored in the variable Fahrenheit.
6. The value of Fahrenheit is printed.
Disclaimer: While we make every effort to update the information, products, and services on our website and related platforms/websites, inadvertent inaccuracies, typographical errors, or delays in updating the information may occur. The material provided on this site and associated web pages is for reference and general information purposes only. In case of any inconsistencies between the information provided on this site and the respective product/service document, the details mentioned in the product/service document shall prevail. Subscribers and users are advised to seek professional advice before acting on the information contained herein. It is recommended that users make an informed decision regarding any product or service after reviewing the relevant product/service document and applicable terms and conditions. If any inconsistencies are observed, please reach out to us.