Shortest path where there is a time constraint

Revision en5, by sudddddd, 2017-04-14 15:44:31

How do we solve a problem in which arrival time and departure time of many flights are given (also source and destination of each flight are given) and we have to find the path between source and final destination which takes least time.

We also have to take care our waiting time for next flight(overall time should be minimised).

There are multiple flights possible from a destination.

X <= 500

N <= 4 * X * (X -1)

Where x is number of stations and N is total number of flights.

Time limit is 3s.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en6 English sudddddd 2017-04-17 18:35:16 532
en5 English sudddddd 2017-04-14 15:44:31 2 Tiny change: 'X <= 500\nN <= 4 *' -> 'X <= 500\n\nN <= 4 *'
en4 English sudddddd 2017-04-14 15:42:42 264
en3 English sudddddd 2017-04-14 15:33:38 4 Tiny change: 'tween two destinations.\n\' -> 'tween two stations.\n\'
en2 English sudddddd 2017-04-14 15:32:50 2 Tiny change: 'nations.\nThere ar' -> 'nations.\n\nThere ar'
en1 English sudddddd 2017-04-14 15:31:45 314 Initial revision (published)