I'm having some problems with the type of the account_balance. I'm not 100% sure what to do to change them to the right types. I also need to make sure that the withdrawal is divisible by 10, I know I use the % statement, but I don't know how the line of code would read. Any help is appreciated!
##display welcome message print("Welcome to a Virtual Credit Union ATM!") counter = 0 while counter < 3: pin = input("Please input your 4-digit PIN: ") if pin == 9876: print("Correct PIN, will continue to menu") break print("Incorrect PIN, please try again") counter += 1 if counter == 3: print("You're locked out, Goodbye") else: print("Onto Menu options") def menu(): ## Your menu design here print "1. View Account Balance" print "2. Withdraw cash" print "3. Make a deposit" print "4. Exit" loop = True while loop: ## While loop which will keep going until loop = False menu() ## Displays menu choice = input("Enter your choice [1-4]: ") if choice == 1: account_balance = (int, 'Your account balance is: $500') print(account_balance) elif choice == 2: print "Withdraw Cash, must be multiple of 10" withdraw = int(input('How much do you want to Withdraw?:')) if withdraw > account_balance: print("Insufficient funds") withdraw = int(input("Enter new amount to Withdraw: ")) elif withdraw <= account_balance: balance = account_balance - withdraw print (' New Balance :', balance) elif choice == 3: print "Make Deposit" deposit = int(input('How much do you want to Deposit?:')) r = input("Are you sure you want to deposit ", deposit, "? [Y/N]") if choice == y: balance = account_balance + deposit print (' New Balance:', balance) elif choice == n: deposit2 = input("Enter the amount you want to deposit") balance = account_balance + deposit2 print (' New Balance:', balance) elif choice == 4: print "Exit, Goodbye!" break loop = False # This will make the while loop to end as not the value of loop is set to False else: # Any integer inputs other than values 1-5 we print an error message raw_input("Wrong option selection. Enter any key to try again..")error message:
File "/Users/jess/PycharmProjects/assignment2/assignment 1.py", line 54, in <module> r = input("Are you sure you want to deposit ", deposit, "? [Y/N]") TypeError: [raw_]input expected at most 1 arguments, got 3