Page 1 of 1

Question 3: Graph The distances between the places in a small town are shown below: 5 d a 4 2 1 C b 8 10 2 e 6 5 сл Z Wr

Posted: Sun Jul 10, 2022 11:29 am
by answerhappygod
 1
1 (106.65 KiB) Viewed 45 times
Question 3: Graph The distances between the places in a small town are shown below: 5 d a 4 2 1 C b 8 10 2 e 6 5 сл Z Write a program that uses graph concept to find lowest bus fare to travel between 2 places using Disjitra algorithm. The program shall fulfil the following requirements: Construct a graph based on the above diagram. Ask user to input origin and destination location. Assume the bus fare rate is RM1.50 per km. Call a function to calculate and display the lowest fare and shortest path from the origin location to destination.