Reconstruct an Itinerary Without a Fixed Start

Given m airline tickets, where each ticket is a directed edge [from, to], reconstruct a complete itinerary that uses every ticket exactly once.

Unlike LeetCode 332, this version has **no fixe...

Example

Unlock to view complete problem details

and practice with sample input/output

Was this article helpful?

View Test Cases & Run Code requires membership

Standard Input
Execution Result: