codemaniacstudio

Write a Python program to enter temperature in Celsius and convert it into Fahrenheit.

Write a Python program to enter temperature in Celsius and convert it into Fahrenheit.

PROGRAM

# Python program to convert Celsius to Fahrenheit
# Input: Temperature in Celsius
celsius = float(input(“Enter temperature in Celsius: “))
# Convert to Fahrenheit
fahrenheit = (celsius * 9/5) + 32
# Output the result
print(“Temperature in Fahrenheit:”, fahrenheit)

OUTPUT

TRY THE ABOVE CODE

Exit mobile version