+ 1

Converter

Anyone to rescue me to make my program run #Celcius to Fanhenheit def celcius_fanhreheit(celcius): fahrenheit = (celius *(9/5)) + 32 return fahrenheit def fahrenheit_celcius(fahrenheit): celcius = (fahrenheit-32) * (5/9) return celcius def conversion(): print("Do you want to convert:") print("1. Celcius to Fahrenheit") print("2. Fahrenheit to Celcius") choice = input("Enter choice(1 or 2):") if choice == "1": c = float(input("Enter degrees in Celcius: ")) f = celcius_fahrenheit(c) print("celcius:",c) print("fahrenheit:",f) elif choice == "2": f = float(input("Enter degrees in Fahrenheit")) c = fahrenheit_celcius(f) print("fahrenheit:",f) print("celcius:",c) looper_boolean = True while looper_boolean: conversion() #prompt to repeat program print("do you want to:") print("1. Convert again") print("2. Exit the program") choice = input("Enter choice(1 or 2):") #choice evaluation if choice == '1': continue else: looper_boolean = False print("Program exiting. Thank you for using the converter")

2nd Jul 2019, 9:02 PM
Faith Tinarwo
Faith Tinarwo - avatar
2 Answers
0
Your first line mis-spells fahrenheit. Your third line mis-spells celcius.
2nd Jul 2019, 10:45 PM
Russ
Russ - avatar
0
thanks Russ corrected still not working but l figured out the indentation was not correct so its workong now
3rd Jul 2019, 3:53 AM
Faith Tinarwo
Faith Tinarwo - avatar