Count Distinct Travelers per City Triplet

Given a trip log where each line is one trip of a traveler: traveler name, timestamp, destination. The log is NOT guaranteed to be ordered by time.

After sorting each traveler's trips by timestamp,...

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: