Amazon interview question

Resolve dependencies by doing a topological sort of a graph. Implement the Linux "find" command. Implement a set whose members have an expiry time, and delete themselves when they expire. Design Ticketmaster.