Example #1
0
def savings_open():
    global acct_number1
    name, opendeposit = input('Enter name : '), int(
        input('How much would like to deposit : '))
    name = Customer(name)
    name.open_saving(acct_number1, opendeposit)
    name.get_deposits()
    acct_number1 += 1
    return name
Example #2
0
def main():
    global acct_number1
    l = [Customer('bob', 1)]
    l[0].open_checking(1, 500)
    l[0].open_saving(2, 50)
    l[0].open_business(3, 2500)
    l[0].get_deposits()
    while True:
        opening_statement()
        xce = int(input('Enter your choice :'))
        if xce == 1:
            xcx = input('Do you already have a account y/n : ')
            if xcx == 'y':
                name1 = input('Name : ')
                mlm = -1
                for i in l:
                    if i.name == name1:
                        mlm += 1
                    else:
                        pass
                print('mlm = ' + str(mlm))
                print(l[mlm].name)
                type = input('Checking,Business,Savings : ')
                deptamt1 = int(input('Deposit amount : '))
                if type.lower()[0] == 'c':
                    l[mlm].open_checking(acct_number1, deptamt1)
                    acct_number1 += 1
                elif type.lower()[0] == 's':
                    l[mlm].open_saving(acct_number1, deptamt1)
                    acct_number1 += 1
                elif type.lower()[0] == 'b':
                    l[mlm].open_business(acct_number1, deptamt1)
                    acct_number1 += 1
                l[mlm].get_deposits()
            else:
                l.append(open_account())
        elif xce == 2:
            type = input('Checking,Business,Savings : ')
            check = verification(l)
            if (check):
                deptamt = int(input('Deposit amount : '))
                axxt_nbr = int(input('Account number : '))
                if type.lower()[0] == 'c':
                    check.make_deposit('C', axxt_nbr, deptamt)
                elif type.lower()[0] == 's':
                    check.make_deposit('S', axxt_nbr, deptamt)
                elif type.lower()[0] == 'b':
                    check.make_deposit('B', axxt_nbr, deptamt)
                check.get_deposits()

        elif xce == 3:
            type = input('Checking,Business,Savings : ')
            check = verification(l)
            if (check):
                deptamt = int(input('Enter withdraw amount : '))
                axxt_nbr = int(input('Account number : '))
                if type.lower()[0] == 'c':
                    check.make_withdrawal('C', axxt_nbr, deptamt)
                elif type.lower()[0] == 's':
                    check.make_withdrawal('S', axxt_nbr, deptamt)
                elif type.lower()[0] == 'b':
                    check.make_withdrawal('B', axxt_nbr, deptamt)
                check.get_deposits()
        elif xce == 4:
            check = verification(l)
            check.get_deposits()
Example #3
0
from code1 import Account, Checking, Business, Customer, Savings
d = {}
x = input('+=')
x = Customer(x)
x.open_business(1, 500)
d[1] = x
print(d[1])
name = input('name')
for c in d:
    if name == c:
        print(c)
Example #4
0
from code1 import Account,Checking,Business,Customer,Savings

bob=Customer('bob',1)
bob.open_checking(1,500)

bob.open_saving(2,50)
bob.open_business(3,2500)
bob.get_deposits()

bob.make_deposit('B',4,500)
bob.get_deposits()
Example #5
0
from code1 import Account, Checking, Business, Customer, Savings
name = Customer('name')
x = raw_input('ssss')
x.get_depoosit()