Skip to content

Glossary: Coding Interviews in Go

Queue

Also written: FIFO

A first-in, first-out line: you take items from the front and add them at the back. In Go BFS it is a slice where `queue[0]` is taken and `queue = queue[1:]` removes it.

Where the book teaches it

Related terms

BFS on a gridStackMessage queue