일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- lcm
- 최소공배수
- 코틀린
- 11기
- 순열
- 11053
- Combination
- 6603
- 매일11시
- 11057
- 백준
- 뒤로가기
- LCS
- 홈화면
- 1182
- 11054
- expo
- Kotlin
- 안드로이드
- itertools
- permutation
- 9095
- 괄호
- 앱
- 1260
- 코테
- 나머지
- Android
- Python
- 파이썬
Archives
- Today
- Total
목록14501 (1)
황소개발자

import sys input = sys.stdin.readline n = int(input()) days = [] for i in range(n): days.append(list(map(int, input().split()))) ans = -999999999 def go(day, total): global ans if day == n: # n에 알맞게 도착했을 때, 정답이 될 수 있다. ans = max(ans, total) return if day > n: # n을 초과한다면 범위 안에 일을 못끝내므로, 정답이 될 수 없다. return go(day + 1, total) # 이번 day는 일을 하지 않고 그냥 넘어간다! go(day + days[day][0], total + days[day][1]) ..
백준 문제 풀이
2020. 2. 28. 20:08