Graph Theory37 sections · 1633 units
Open in Course

Euler Tour Variants

(Different approaches)

There are three common Euler tour variants: entry-only, entry-exit, and full tour. Entry-only stores tin[v] (no touttout). Entry-exit stores both tin[v] and tout[v].

Full tour stores the entire sequence of visited nodes. Each variant solves different problems. Choose based on what queries you need to answer. Entry-exit is the most common for subtree queries. Full tour is used for LCA via range minimum query. Entry-only is useful for ancestor checks.