Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions Bank.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
class Bank_Account:
def __init__(self):
self.balance = 1000
print("Welcome to Cash Money ATM")

def deposit(self):
amount=float(input("Enter the amount you would like to Deposited: "))
self.balance += amount
print("Amount Deposited:",amount)

def withdraw(self):
amount = float(input("Enter amount to be Withdrawn: "))
if self.balance >= amount:
self.balance -= amount
print("You Withdrew:", amount)
else:
print("Insufficient balance ")

def display(self):
print("Net Available Balance=",self.balance)


s = Bank_Account()

s.deposit()
s.withdraw()
s.display()