Skip to content

Glossary: Algorithms Beyond the Basics in Go

inf (infinity constant)

Also written: inf, 1 << 60

A big constant, `1 << 60`, meaning "not possible yet" or "no route found". It loses every comparison and is safe to add 1 to, unlike `math.MaxInt`.

Where the book teaches it

Related terms

Integer overflowDijkstra's algorithm