Answers for "how to convert dollars to rupees and rs to dollar in python"

1

how to convert dollars to rupees and rs to dollar in python

print('hello welcome to converter of rs to dollar and dollar to rs')

print()

carry_on = True
while carry_on:
    try:
        ask = int(input('write what do you want to do find? for finding dollar to rs type "1"   or to find rs to dollar write "2":- '))
    except ValueError:
        print('inccorrect input')
    
    if ask == 1:
        try:
            dollars = float(input("Please enter dollars value:"))
            converter = dollars * 72.90
            print(converter,"Rupees")
        except ValueError:
            print('incorrect input')
            
    elif ask == 2:    
        rupees = float(input("Please enter rupees:"))
        dollars_converter = rupees / 72.90
        print(dollars_converter, " Dollars")
    
    else:
        print('incorrect input')
    
    User_think = input('Do you want to cotinue? write "1 or one" if you want to continue or "2 or two" to exit:- ').upper()
    if User_think == 1 or "ONE":
        go = True
    elif User_think == 2 or "TWO":
        go = False
    else:
        print('wront input closing the software')
        go = False
Posted by: Guest on August-09-2021

Code answers related to "how to convert dollars to rupees and rs to dollar in python"

Python Answers by Framework

Browse Popular Code Answers by Language