https://lucky516.tistory.com/5
import heapq l = [] heapq.heappush(l,(t,i))
위처럼 그냥 tuple로 넣게 되면 t에 대해서 최소힙, t가 같다면 i에 대해서 최소힙이 적용된다.