Back Arise

Visualization sandbox

Free graph sample

Which node leaves the queue next?

Try one breadth-first search step. Node 1 has been visited, and its neighbors 2 and 3 are waiting in the queue.

Purple nodes are waiting. The double ring marks the current visit.

BFS queue
Front →23

Choose the next node to visit.

Neighbors enter in ascending order. BFS takes the oldest waiting node first.

Build your own graphs with Interview Prep or Oni.

Edit directed and weighted graphs, or generate trees.

Compare passesCheckout is closed right now.
Esc
↑↓Move ↵Open Ctrl↵New tab >Actions ?Shortcuts

Keyboard shortcuts

Anywhere

Open search
CtrlKor /
Show these shortcuts
?
Close a window or menu
Esc

In search

Move through results
↑or ↓
Open the result
↵
Open in a new tab, or a problem on its judge
Ctrl↵
List actions only
>
Remove the filter
⌫

Go to

Learn
GthenL
Practice
GthenP
Assessments
GthenA
System design
GthenS
Companies
GthenC
My profile
GthenM
Today's quest
GthenT
Home
GthenH