From 7ffc988723a927eaba135dd9708a6ae77cfdeb81 Mon Sep 17 00:00:00 2001 From: doitcodingtest <108266421+doitcodingtest@users.noreply.github.com> Date: Wed, 13 Mar 2024 18:55:38 +0900 Subject: [PATCH 1/4] =?UTF-8?q?Update=20P1325=5F=ED=9A=A8=EC=9C=A8?= =?UTF-8?q?=EC=A0=81=EC=9D=B8=ED=95=B4=ED=82=B9.py=20=EC=8B=9C=EA=B0=84?= =?UTF-8?q?=EC=B4=88=EA=B3=BC=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...0\354\240\201\354\235\270\355\225\264\355\202\271.py" | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git "a/\352\267\270\353\236\230\355\224\204/P1325_\355\232\250\354\234\250\354\240\201\354\235\270\355\225\264\355\202\271.py" "b/\352\267\270\353\236\230\355\224\204/P1325_\355\232\250\354\234\250\354\240\201\354\235\270\355\225\264\355\202\271.py" index 5edebdf..7b0f15f 100644 --- "a/\352\267\270\353\236\230\355\224\204/P1325_\355\232\250\354\234\250\354\240\201\354\235\270\355\225\264\355\202\271.py" +++ "b/\352\267\270\353\236\230\355\224\204/P1325_\355\232\250\354\234\250\354\240\201\354\235\270\355\225\264\355\202\271.py" @@ -7,6 +7,7 @@ def BFS(v): + visited = [False] * (N + 1) queue = deque() queue.append(v) visited[v] = True @@ -19,18 +20,14 @@ def BFS(v): queue.append(i) -for _ in range(M): +for i in range(M): S, E = map(int, input().split()) A[S].append(E) for i in range(1, N + 1): # 모든 노드에서 BFS 실행 - visited = [False] * (N + 1) BFS(i) -maxVal = 0 -for i in range(1, N + 1): - maxVal = max(maxVal, answer[i]) - +maxVal = max(answer) for i in range(1, N + 1): if maxVal == answer[i]: print(i, end=' ') From 2e48a5331aae6a7a00ea083583de8efab0349d9b Mon Sep 17 00:00:00 2001 From: doitcodingtest <108266421+doitcodingtest@users.noreply.github.com> Date: Fri, 31 Oct 2025 01:24:19 +0900 Subject: [PATCH 2/4] =?UTF-8?q?Rename=20P1377=5F=EB=B2=84=EB=B8=94?= =?UTF-8?q?=EC=86=8C=ED=8A=B81.py=20to=20P1377=5F=EB=B2=84=EB=B8=94?= =?UTF-8?q?=EC=A0=95=EB=A0=AC1.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../P1377_\353\262\204\353\270\224\354\240\225\353\240\2541.py" | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename "\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\206\214\355\212\2701.py" => "\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\240\225\353\240\2541.py" (95%) diff --git "a/\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\206\214\355\212\2701.py" "b/\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\240\225\353\240\2541.py" similarity index 95% rename from "\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\206\214\355\212\2701.py" rename to "\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\240\225\353\240\2541.py" index 406b09b..a4a0d93 100644 --- "a/\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\206\214\355\212\2701.py" +++ "b/\354\240\225\353\240\254/P1377_\353\262\204\353\270\224\354\240\225\353\240\2541.py" @@ -10,4 +10,4 @@ for i in range(N): if Max < sorted_A[i][1] - i: # 정렬 전 index - 정렬 후 index 계산의 최댓값 저장하기 Max = sorted_A[i][1] - i -print(Max + 1) \ No newline at end of file +print(Max + 1) From 2e7b26934af4f9ffc881cf19a166fea0e5814af6 Mon Sep 17 00:00:00 2001 From: doitcodingtest <108266421+doitcodingtest@users.noreply.github.com> Date: Fri, 31 Oct 2025 01:24:36 +0900 Subject: [PATCH 3/4] =?UTF-8?q?Rename=20P1517=5F=EB=B2=84=EB=B8=94?= =?UTF-8?q?=EC=86=8C=ED=8A=B82.py=20to=20P1517=5F=EB=B2=84=EB=B8=94?= =?UTF-8?q?=EC=A0=95=EB=A0=AC2.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../P1517_\353\262\204\353\270\224\354\240\225\353\240\2542.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\206\214\355\212\2702.py" => "\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\240\225\353\240\2542.py" (100%) diff --git "a/\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\206\214\355\212\2702.py" "b/\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\240\225\353\240\2542.py" similarity index 100% rename from "\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\206\214\355\212\2702.py" rename to "\354\240\225\353\240\254/P1517_\353\262\204\353\270\224\354\240\225\353\240\2542.py" From dfb8ee001d4bdf55536954fb8613419752fdd2a4 Mon Sep 17 00:00:00 2001 From: doitcodingtest <108266421+doitcodingtest@users.noreply.github.com> Date: Fri, 31 Oct 2025 01:30:53 +0900 Subject: [PATCH 4/4] =?UTF-8?q?Rename=20P1206=5FDFS=EC=99=80BFS.py=20to=20?= =?UTF-8?q?P1260=5FDFS=EC=99=80BFS.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../P1260_DFS\354\231\200BFS.py" | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename "\355\203\220\354\203\211/P1206_DFS\354\231\200BFS.py" => "\355\203\220\354\203\211/P1260_DFS\354\231\200BFS.py" (100%) diff --git "a/\355\203\220\354\203\211/P1206_DFS\354\231\200BFS.py" "b/\355\203\220\354\203\211/P1260_DFS\354\231\200BFS.py" similarity index 100% rename from "\355\203\220\354\203\211/P1206_DFS\354\231\200BFS.py" rename to "\355\203\220\354\203\211/P1260_DFS\354\231\200BFS.py"