Skip to content

Commit a2414f7

Browse files
Update dfs_stack.py
1 parent d87e1a4 commit a2414f7

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

Algorithm_with_DataStructure/dfs_stack.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,6 @@
2020
# - 사이클 탐지
2121
# - 그래프 연결 성분 찾기
2222

23-
# 5. DFS 상세 과정(스택 활용):
24-
# - 시작 노드(1)를 스택에 넣고, 방문 처리를 한다.
25-
# - 스택의 최상단 노드에 방문하지 않은 인접 노드가 있으면 그 인접 노드를 스택에 넣고 방문 처리를 한다.
26-
# 방문하지 않은 인접 노드가 없으면 스택에서 최상단 노드를 꺼낸다.
27-
# - 위 과정을 스택이 비어있을 때까지 반복한다.
2823

2924

3025
def dfs(graph, start_node):

0 commit comments

Comments
 (0)