Notice
Recent Posts
Recent Comments
Link
| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 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 | 31 |
Tags
- BOJ 2606
- boj 11053
- 파이썬
- BFS
- 가장 긴 증가하는 부분수열
- 백준 1535
- 12865
- 백준 12015
- 데카르트 곱
- 미로탐색
- 백준 9252
- dfs
- 대소비교
- python
- 소수찾기
- 백준_2178
- 8-queen
- 평범한 배낭
- list
- 알고리즘
- 타겟 넘버
- 2606
- 9663
- 냅색
- LCS2
- 백준
- 프로그래머스
- 증가하는 부분수열 2
- 백준 2606
- 리스트
Archives
- Today
- Total
목록Algorithm (1)
Devlog_by_0giru
[프로그래머스] 여행 경로
# 테스트 케이스 2 통과 / 실패 def solution(tickets): nation_num = len(tickets) graph = [] graph_new = [] result = [] for inf in tickets: graph.append([inf[0]]) for inf in tickets: for i in range(nation_num): if inf[0] == graph[i][0]: graph[i].append(inf[1]) for inf in graph: if inf not in graph_new: graph_new.append(inf) for inf_new in graph_new: temp1 = inf_new[0] inf_new.sort() temp2 = inf_new.index(tem..
[PS]
2021. 2. 15. 15:30