I would like to submit the following question I was asked recently during my technical interview at Google. I'm rephrasing the question to make it clear for everyone to understand: - You are going on a one-way flight trip that includes billions of layovers. - You have 1 ticket for each part of your trip (i.e: if your trip is from city A to city C with a layover in city B, then you will have 1 flight ticket from city A to city B, and 1 flight ticket from city B to city C. - Each layover is unique. You are not stopping twice in the same city. - You forgot the original departure city. - You forgot the final destination city. - All the tickets you have are randomly sorted. Question are: - Design an algorithm to reconstruct your trip with minimum complexity. - How would you improve your algorithm. Example: - randomly sorted: New York->London San Francisco-> Hong Kong Paris->New York London->San Francisco - sorted: Paris->New York New York->London London->San Francisco San Francisco-> Hong Kong3 4826
Which is better a char, short or int type for optimization?
What are the key innovations of sap s/4hana simple logistics?
how can u prepare the test plan?
How can done the Accounting of WTC ? OR WTC treat (Take) like Service tax credit?
What is the use of expression tree in c#?
What is dynamic transaction backout?
what are various server configuration files?
What is a generic code?
Why do you want to join accenture and why not other IT firms?
How is it informed when the server is added to the cluster?
How do we print “
creates a new line in html” in jsp?
What is the stuff and how does it differ from the replace function?
How can you implement encapsulation in asp.net?
What is an exception cell?
What is the difference between SOURCE and TARGET BASED COMMITS? What are the deliverables?in your project?