백준 4485 녹색 옷 입은 애가 젤다지? 혼내주기
문제 설명이 너무 귀엽다. ㅋㅋㅋㅋㅋㅋ 엄청난 초월번역. 다익스트라로 루피를 가장 적게 잃은 순으로 방문한적이 없는 동굴만 탐색하다 출구에 도착하면 종료하면 된다. #include #include #include using namespace std; int dx[4] = {1, 0, -1, 0}; int dy[4] = {0, 1, 0, -1}; int map[125][125], visited[125][125]; int n; int d(){ priority_queue pq; pq.push({0, {0, 0}}); visited[0][0] = 0; while(!pq.empty()){ int cost = -pq.top().first, fx = pq.top().second.first, fy = pq.top()...
혼내주기
2021. 8. 2. 00:06