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 |
Tags
- sort()
- list.sorted()
- 피보나치 수
- Boto3
- Algorithm
- Python 나머지
- python3
- string
- 알고리즘 풀이
- Python
- 알고리즘
- sting position
- index
- List to String
- homebrew-core is a shallow clone.
- set to list
- Modified Date
- Python 몫
- List 초기화
- Split
- zip()
- cask
- COUNT
- list to set
- List
- RecursionError
- list.pop(0)
- 프로그래머스
- permutations
- Unknown command: cask
Archives
- Today
- Total
목록list to set (1)
데이터와 코드로 세상을 바라봅니다.

# 우선순위의 종류를 알아야 한다. (그래야 비교 가능) # 문서 순서를 저장해야 한다. # 프린터 (return)을 계산해야 한다. # 처리 로직 ## 제일 큰 우선 순위 종류가 우선순위 목록에 있는지 확인 ## 우선순위 목록에 첫번째 있는 문서의 우선순위를 POP ## 이와 동일 선상에서 문서 순서 첫번째 list 대상을 POP ## 비교해서 같으면 print ## 다르면 맨 뒤에 insert (문서 순서도 동일) from queue import Queue def solution(priorities, location): answer = 0 doc_order = list(range(0,len(priorities))) ## document 순서 Queue 정렬 완료. set_p = set(prioriti..
Code/Python
2021. 2. 19. 17:24