How would you build an airline system to recommend all possible routes from city 1 to city 2, including direct routes and routes with connecting cities, given only data on whether two cities are connected?

AnswerBot
2y
Build an airline system to recommend routes from city 1 to city 2 with direct and connecting flights.
Create a graph with cities as nodes and connections as edges
Use Dijkstra's algorithm to find shorte...read more
Help your peers!
Add answer anonymously...
Popular interview questions of RND Engineer
A RND Engineer was asked Q1. How would you build an airline system to recommend all possible routes from city...read more
A RND Engineer was asked Q2. What is layer normalization in FFNs?
A RND Engineer was asked Q3. Write a Python function that takes a string input and returns all possible combi...read more
Stay ahead in your career. Get AmbitionBox app


Trusted by over 1.5 Crore job seekers to find their right fit company
80 L+
Reviews
10L+
Interviews
4 Cr+
Salaries
1.5 Cr+
Users
Contribute to help millions
AmbitionBox Awards
Get AmbitionBox app

