728x90
반응형
currentMoney = 100000
print('1: Deposit, 2: Withdraw, 3: CheckBalance 4: Exit')
option = int(input('Please Enter Your Choice'))
if option == 1: # 예금 업무
money = int(input('입금액을 입력하세요 :'))
currentMoney += money
print('잔고는 ',format(currentMoney,','), '입니다')
elif option == 2: # 출금업무
money = int(input('출금액을 입력하세요 :'))
if money > currentMoney:
print('잔액이 모자랍니다!')
else:
currentMoney -= money
print('잔고는 ',format(currentMoney,','), '입니다')
elif option == 3: # 잔고 확인
print('잔고는 ',format(currentMoney,','),' 입니다')
elif option == 4: # 종료
print('Thank you for visiting our banl! Good Bye!')
728x90
반응형
'프로그램' 카테고리의 다른 글
[파이썬] 문제 : 클래스로 게임 만들기 (1) | 2022.11.22 |
---|---|
[파이썬] 문제 : 키보드 입력 받아 함수 실행 하기 (0) | 2022.11.22 |
[파이썬] 문제 : DataFrame 에러 (not in index) (0) | 2022.11.22 |
[파이썬] 문제 : 두 개의 정수를 입력받아 사칙연산 하기 (0) | 2022.11.22 |
[파이썬] 문제 : 집합 포함 관계 (0) | 2022.11.22 |
댓글