Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Need Help in making these steps function in my program to show. Python is being

ID: 3534401 • Letter: N

Question

Need Help in making these steps function in my program to show. Python is being use for this problem.


1) wrong account information or 2) present a menu of choices - check account balance, withdraw, deposit or quit. The method should complete the task chosen and then return to presenting the menu and this should go on until the user chooses to quit.


class ATM:


BankMasterFile = "BankMasterFile.csv"


def __init__(self):


rdr = reader(ATM.BankMasterFile)

self.accountObjects = []

for line in rdr:

accountObjects = BankAccount(line[0]+" "+line[1],int(line[2]),int(line[3]),float(line[4]))

self.accountObjects.append(accountObjects)


def processTransactions(self):

account_id = int(input('What is the account id?'))

account_pin = int(input('What is the pin?'))


for aca in self.accountObjects:


if aca.account_id == account_id and aca.account_pin == account_pin:

criterion = askQuestion("Choose search criterion", ("Total account","Account id","Account pin") )


if criterion == "Check Account Balance":

aca.printInformation()


elif criterion == "Withdraw":

amount = eval(input('How much do you wish to withdraw?'))

aca.withdrawl(amount)

aca.printInformation()


elif criterion == "Deposit":

amount = eval(input('How much do you wish to deposit?'))

aca.deposit(amount)

aca.printInformation()


elif criterion == "Quit":

exit


elif aca.account_id == account_id or aca.account_pin == account_pin:

print('WRONG ACCOUNT INFORMATION')


else:

return


def main():

system1 = ATM()

system1.processTransactions()


main()

Explanation / Answer

import sys

import os

import time

def entrance():

print face

try:

x = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if x == 1234:

print " Verifying PIN..."

time.sleep(5)


print " PIN correct..."

time.sleep(3)

print " Welcome to Shyne's ATM Machine."

main()

else:

print " Incorrect password. You have 2 tries left to make."

m = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if m == 1234:

print " Verifying PIN..."

time.sleep(5)

print " PIN correct..."

time.sleep(3)

print " Welcome to Shyne's ATM Machine."

main()

else:

print " Incorrect password. You have 1 try left to make."

k = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if k == 1234:

print " Verifying PIN..."

time.sleep(5)

print " PIN correct..."

time.sleep(3)

print " Welcome to Shyne's ATM Machine."

main()

else:

print " Account Blocked, U made more than 3 attempts. Goodbye" sys.exit(1) except ValueError:

print " Integers only Bro...!!!!"

entrance()

def main():

try:

time.sleep(3)

print ' Main Menu: '

print " [1] - Balance Enquiry"

print " [2] - Withdrawal"

print " [3] - Deposit Money"

print " [4] - Exit"

time.sleep(2)

y = int(raw_input(" What transaction would you like to carry out? : "))

balance = 50000

if y == 1:

print ' Your Remaining Balance is', balance

entrance()

elif y == 2:

print """

[1] - 500 [4] - 5000

[2] - 1000 [5] - 10000

[3] - 2000 [6] - 20000

"""

z = int(raw_input(" How much do U wanna withdraw : "))

if z == 1:

print ' You are about to withdraw', 500, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 500, 'from your account.'

print ' Your New Account Balance is', balance - 500

entrance()

elif a == 2:

print """ Transaction Cancelled'

Bye.......

"""

entrance()

else:

print 'Please enter a Valid Option'

main()

if z == 2:

print ' You are about to withdraw', 1000, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 1000, 'from your account.'

print ' Your New Account Balance is', balance - 1000

entrance()

elif a == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:

print 'Please enter a Valid Option'

main()

if z == 3:

print ' You are about to withdraw', 2000, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 2000, 'from your account.'

print ' Your New Account Balance is', balance - 2000

entrance()

elif a == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:]

print 'Please enter a Valid Option'

main()

if z == 4:

print ' You are about to withdraw', 1000, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 5000, 'from your account.'

print ' Your New Account Balance is', balance - 5000

entrance()

elif a == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:

print 'Please enter a Valid Option'

main()

if z == 5:

print ' You are about to withdraw', 10000, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 10000, 'from your account.'

print ' Your New Account Balance is', balance - 10000

entrance()

elif a == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:

print 'Please enter a Valid Option'

main()

if z == 6:

print ' You are about to withdraw', 20000, 'from your account'

a = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if a == 1:

print ' You withdrew', 20000, 'from your account.'

print ' Your New Account Balance is', balance - 20000

entrance()

elif a == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:

print 'Please enter a Valid Option'

main()

else:

print ' Please enter a Valid Option'

main()

elif y == 3:

c = int(raw_input(" How much do U wanna deposit : "))

print ' You are about to deposit',c, 'to your account'

d = int(raw_input(" Are you sure you want to continue? (1-Yes / 2-No) : "))

if d == 1:

print ' You deposited', c, 'to your account'

print ' Your New Account Balance is', balance + c

print ' Thanks for transacting with Us...'

print ' Bye.....'

entrance()

elif d == 2:

print ' Transaction Cancelled'

print ' Bye.......'

entrance()

else:

print 'Please enter a Valid Option'

entrance()

elif y == 4:

print ' Thank you for transacting with us....'

time.sleep(3)

print ' Goodbye....!'

time.sleep(3)

entrance()

elif y == 5:

print " Exiting Application..."

time.sleep(3)

print " Goodbye...!"

time.sleep(3)

sys.exit(1)

else:

print ' Thats not a Valid Option. Pls choose one.'

main()

except ValueError:

print " Integers only Bro...!!!!"

main()

print facetry:

x = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if x == 1234:

print " Verifying PIN..."

time.sleep(5)

print " PIN correct..."

time.sleep(3)

print " Welcome to Snyhe's ATM Machine."

main()

else:

print " Incorrect password. You have 2 tries left to make

m = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if m == 1234:

print " Verifying PIN..."

time.sleep(5)

print " PIN correct..."

time.sleep(3)

print " Welcome to Shyne's ATM Machine."

main()

else

print " Incorrect password. You have 1 try left to make."

k = int(raw_input(" Welcome, pls enter ur 4-digit PIN no : "))

if k == 1234:

print " Verifying PIN..."

time.sleep(5)

print " PIN correct..."

time.sleep(3)

print " Welcome to Shyne's ATM Machine."

main()

else:

print " Account Blocked, U made more than 3 attempts. Goodbye"

sys.exit(1)except ValueError:

print " Integers only Bro...!!!!"

entrance()

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote