Question: Consider 8 different cities ( not zmir and not Van ) in Turkey including your hometown and your parents hometowns ( If you are not
Consider
different cities
not
zmir and not Van
in Turkey including
your hometown and your parents
hometowns
If you are not from
Turkey, choose the cities you have visited or you want to visit
Construct a table for distances between the
cities including the
cities you have chosen and
zmir and Van using the data given below as a Let X be the average distance between these
cities
Discuss if the following questions can be solved using Dijkstra algorithm
or dynamic programming algorithm. If yes, then write a computer
program that implements the algorithm.
prefebly CPP or C
Assume that you will be given a task where you start from
zmir
visit some of the other
cities on the way and reach to Van,
where you stay exactly one night in an intermediate city, move to
another one next morning and reach there in the same evening.
You may come back to the same intermediate city. What is the
minimum distance you must travel for such a task
including at
least one night
stay
What is the minimum distance if the task
contains exactly
nights
stay.
Assume that for the above task you spend
TL per km and earn X
TL for each city you visit. Which tasks are the best and worst in
terms of total income
Further information:
In Task
there are two subtasks:
The first one is to find the minimum distance from
zmir to Van if you visit at least one intermediate city.
The second one is to find the minimum distance from
zmir to Van if you visit exactly four intermediate cities.
The number of night stays
The number of intermediate cities
you stay one night at an intermediate city
In Task
you should analyse Task
with a change in the cost function.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
