Python Forum
Need help with pseuo -bank account using OOP
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need help with pseuo -bank account using OOP
#27
def enter_pin():
     while True:
      pin = int( input("Enter pin "))# keeps asking for the correct pin 
      if pin in data:
         d = data[pin]
         while True:
    
             return data[pin]
       if pin[0] in 'qQ':
            break
       else:
           print("INCORRECT PIN TRY AGAIN")


My code currently looks like this

right it's throwing an issue with if pin[0] in 'qQ':, saying the int' object is not subscriptable
Reply


Messages In This Thread
RE: Need help with pseuo -bank account using OOP - by obieze998 - Jul-24-2017, 04:34 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Different results of code with local account and technical account dreyz64 7 3,789 Mar-05-2020, 11:50 AM
Last Post: dreyz64

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020