Algorithm/Dijkstra 썸네일형 리스트형 [프로그래머스] 등산코스 정하기 https://school.programmers.co.kr/learn/courses/30/lessons/118669 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr #include #include #include #include // https://school.programmers.co.kr/learn/courses/30/lessons/118669 #define MAX 50001 #define INF 1e9 using namespace std; typedef pair pii; vector graph(MAX); // { from, to, intensity }.. 더보기 [백준] 최단경로 1753번 - Python https://www.acmicpc.net/problem/1753 1753번: 최단경로 첫째 줄에 정점의 개수 V와 간선의 개수 E가 주어진다. (1 ≤ V ≤ 20,000, 1 ≤ E ≤ 300,000) 모든 정점에는 1부터 V까지 번호가 매겨져 있다고 가정한다. 둘째 줄에는 시작 정점의 번호 K(1 ≤ K ≤ V)가 www.acmicpc.net import sys input=sys.stdin.readline import heapq V,E=map(int,input().split()) #정점개수, 간선개수 K=int(input()) #시작정점 graph=[[] for _ in range(V+1)] distance=[float('inf')]*(V+1) visited=[False]*(V+1) for _ in.. 더보기 이전 1 다음