본문 바로가기

하루코딩/python 하루코딩

[Python] 프로그래머스 기출테스트 0LV

728x90
반응형

 

start = int(input())
before = int(input())
after = int(input())

money = start
month = 1
while money < 70:
    money += before
    month += 1
while money < 100:
    money += after
    month += 1

print(month)​

 

반응형