Question: write code in C++ In this project, you should design and implement graph algorithms to store and search graphs. World Airline Company (WAC) flies to

write code in C++

In this project, you should design and implement graph algorithms to store and search graphs. World Airline Company (WAC) flies to many destinations worldwide including: Moscow, Seoul, Tokyo, Hong Kong, and London. Using the following detailed information regarding airline flight routes from city and its destination cities that WA flights to.

From: Moscow

To: Hong Kong

London

From: Seoul

To: Moscow

Hong Kong

From: Tokyo

To: Moscow

Hong Kong

London

From: Hong Kong

To: Moscow

London

From: London

To: Moscow

Seoul

Task

Your task is to design and implement algorithms to answer the following questions:

I am in city A, can I fly to city B with less than x connections? Give me the route with the smallest number of connections or tell me there is no such a route.

Give me the route with the smallest number of connections from city A to city D through city B and C. (the order of B and C is not important). Or tell me there is no such a route

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!