#program to calculate arithematic oprations import math while True: print('1. Addition\n2. Subtraction\n3. Multiplication\n4. Division\n5. Square Root') choice = int(input('Enter Your Choice :')) list1 = [1,2,3,4,5] if choice not in list1: print('WRONG CHOICE!!\nTRY AGAIN!!') continue if choice == 1: inp1 = float(input('Enter The First Number :')) inp2 = float(input('Enter The Second Number :')) print('Your Sum =',inp1 + inp2) elif choice == 2: inp1 = float(input('Enter The First Number :')) inp2 = float(input('Enter The Second Number :')) print(f'Your Difference = {inp1 - inp2}') elif choice == 3: inp1 = float(input('Enter The First Number :')) inp2 = float(input('Enter The Second Number :')) print('Your Product=',inp1*inp2) elif choice == 4: inp1 = float(input('Enter The First Number :')) inp2 = float(input('Enter The Second Number :')) print('Your quotient =',inp1/inp2) elif choice == 5: inp1 = float(input('Enter The Number :')) print(f'Square Root of {inp1} is {math.sqrt(inp1)}') inp3 = input('What Do You Want to do?(y or n) :') if inp3 == 'y': continue else: break