Learn
Practice
Newsletter
Resources
Animations
New
F
Toggle theme
0
F
0
Toggle menu
← Back to All Animations
Is Graph Bipartite?
Bookmark
Input
Odd cycle inside
Square
Triangle
Hexagon
Custom
graph
=
[[1,2,3],[0,2],[0,1,3],[0,2]]
0
1
2
3
A
B
algo
master
.
io
Step:
Try to split the 4 nodes into two sets, A and B, so every edge crosses between them
0 / 15
Input
Odd cycle inside
Square
Triangle
Hexagon
Custom
graph
=
[[1,2,3],[0,2],[0,1,3],[0,2]]
0 / 15
0
1
2
3
A
B
algo
master
.
io
Step:
Try to split the 4 nodes into two sets, A and B, so every edge crosses between them