Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- global payee
- global bal
- global emial
- global pta
- global sname
- global pname
- global all
- def c1(): #Call 1
- print("Please enter an ID")
- global ID #Makes the ID variable avaliable globally
- ID=input("ID: ") #aks for an ID
- c2()
- def c2(): #Call 2
- if ID=="1": #Checks if the entered ID is in the database
- print("Please enter your security code")
- c3()
- def c3(): #Call 3
- global sc
- sc=input("Secure Keyboard: ")
- scc()
- def scc(): #Security Code Check
- if sc=="1":
- print("Welcome to BBA backend")
- upp()
- def upp(): #User profile protocol
- global fname
- fname="Kevin" #forename/first name
- global sname
- sname=" Dontenville" #surname
- global bal
- bal=int(10000) #balance
- global email
- email="Kevin@keepnet.net" #Email address
- global pnum
- pnum="01568 77002" #Phone number
- global cor
- cor="UK" #country of residence
- func()
- def func():
- print("Please select a function by entering a number:")
- print("| 1 - Balance")
- print("| 2 - Transfer")
- print("| 3 - Loans ")
- print("| 4 - Log out ")
- print("| 5 - Register")
- global fcs
- fcs=input("Function: ") #fcs=func select
- fci() #Function input call
- def fci():
- if fcs=="1":
- bala()
- else:
- if fcs=="2":
- transf()
- else:
- if fcs=="3":
- loans()
- else:
- if fcs=="4":
- os()
- else:
- if fcs=="5":
- register()
- else:
- print("Unrecognised Function")
- func()
- def bala():
- print("---------------------------------------------------------------------------")
- print("| Your current balance is (GBP):",bal)
- print("| Balance incl pending is (GBP):",bal)
- print("---------------------------------------------------------------------------")
- func()
- def transf():
- print("To transfer please enter a PID")
- global payee
- payee=input("Payee ID: ")
- pn() #payee name
- print("Please wait while we validate your request....")
- print("Validated")
- print("Please enter an amount to transfer in GBP")
- global pta
- global bal
- pta=int(input("£"))
- if bal<pta:
- print("Insuffienct funds")
- transf()
- else:
- print("You are transfering to",payee)
- print("Please enter your Security pin to continue")
- sc=input("Security Pin: ")
- if sc=="1":
- bal-=pta
- print("Your new balance is",bal)
- print("Succesfully Transfered")
- func()
- else:
- print("Incorrect: one more attempt")
- print("Please enter your Security pin to continue")
- sc=input("Security Pin: ")
- if sc=="1":
- bal-=pta
- print("Your new balance is",bal)
- print("Successfully transfered.")
- func()
- else:
- print("Failed 2 times")
- transf()
- def pn():
- global payee
- if payee=="2":
- payee="Max Dontenville"
- else:
- if payee=="3":
- payee="Polly Dontenville"
- else:
- if payee=="4":
- payee="Heather Dontenville"
- else:
- print("No such payee.")
- transf()
- def loans():
- print("Checking if you are eligible for a loan...")
- lmin=int(8999)
- if bal>lmin:
- loanfunc()
- else:
- print("Error: You need £9,000 for loan eligibility!")
- func()
- def loanfunc():
- global bal
- print("| - Loaning - |")
- print("- Intrest rates of 16.7% [Bank of england mininum]")
- print("- Up to Triple Your current balance.")
- print("- Annual Payments")
- print("| - - - - - - |")
- print("")
- print("You can have up to:")
- if bal>10000:
- print(bal*2)
- elif bal>150000:
- print(bal*3)
- print("Please enter an amount you would like to withdraw in GBP:")
- loana=int(input("£")) #loana=loan amt
- print("You would like to withdraw",loana)
- if loana>bal*2:
- print("")
- print("")
- print(" -!!- You cant withdraw more than double your balance -!!- ")
- print("")
- print("")
- loanfunc()
- elif loana<bal*2:
- print("Accepted value.")
- if loana>20000:
- print("You have until 6/10/25 to repay this loan")
- elif loana<15000:
- print("You have until 6/11/23 to repay this loan")
- print("To complete this loan please anter your security code:")
- sc=input("Security Pin: ")
- if sc=="1":
- bal+=loana
- print("Your new balance is",bal)
- func()
- else:
- print("Incorrect code 1/2 attempts")
- print("To complete this loan please anter your security code:")
- sc=input("Security Pin: ")
- if sc=="1":
- bal+=loana
- print("Your new balance is",bal)
- func()
- else:
- print("Incorrect code 2/2 attempts")
- func()
- def os(): #open system
- print("Welcome to the official backend for the British Banking Association")
- c1()
- def register():
- print("Thanks for considering registering with BBA.")
- print("Please carefully follow the instructions below")
- print("Please add your country of residence (e.g. `UK`):")
- global country
- country=input("Country: ")
- print("Please enter your name: ")
- global fname
- fname=input("First name: ")
- global sname
- sname=input("Surname: ")
- print("Please enter your phone number:")
- global pnum
- pnum=int(input("Phone number: "))
- print("Please enter your email address:")
- global email
- email=input("Email address: ")
- print("Thankyou for registering with BBA")
- print("Registered information:")
- print("Country -",country)
- print("Full name -",fname +" "+sname)
- print("Phone Number -",pnum)
- print("Email -",email)
- print("Thanks for joining the British Banking Association.")
- print("Your personal ID is '10'")
- print("Your security code is '18596'")
- func()
- print("Welcome to the official backend for the British Banking Association")
- c1()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement