Skip to content

Commit 8a4ec96

Browse files
modified: graphs/check_bipartite_graph_all.py
1 parent 36955c5 commit 8a4ec96

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: graphs/check_bipartite_graph_all.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ def breadth_first_search() -> bool:
4141
return False
4242
return True
4343

44-
for i in range(len(graph)):
45-
if not visited[i]:
44+
for i, v in enumerate(visited):
45+
if not v:
4646
queue.put(i)
4747
color[i] = 0
4848
if breadth_first_search() is False:

0 commit comments

Comments
 (0)