Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit881e07d

Browse files
authored
Update 1.py
1 parentc59eaf4 commit881e07d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎18/1.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ def union_parent(parent, a, b):
1414
else:
1515
parent[a]=b
1616

17-
# 여행지의 개수와 여행 계획에 속한 여행지의 개수입력 받기
17+
# 여행지의 개수와 여행 계획에 속한 여행지의 개수입력받기
1818
n,m=map(int,input().split())
19-
parent= [0]* (n+1)# 부모 테이블초기화하기
19+
parent= [0]* (n+1)# 부모 테이블초기화
2020

2121
# 부모 테이블상에서, 부모를 자기 자신으로 초기화
2222
foriinrange(1,n+1):
@@ -29,7 +29,7 @@ def union_parent(parent, a, b):
2929
ifdata[j]==1:# 연결된 경우 합집합(Union) 연산 수행
3030
union_parent(parent,i+1,j+1)
3131

32-
# 여행 계획입력 받기
32+
# 여행 계획입력받기
3333
plan=list(map(int,input().split()))
3434

3535
result=True

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp