shortest path problem

Правка en1, от A.ElGamal, 2015-09-04 04:01:19

544D - Destroying Roads for this problem I tried using Dijkstra and mark edges I used then I would loop on edges and count the number of unused edges then print them, but the problem is the following: 1)dijkstra gives me the "shortest" path where the problem needs that path does not exceed some fixed value so that I can delete more edges at the end 2)I can not handle the case when dijkstra select two ways for 1st and 2nd case that does not intersect (because it looks for shortest path) where it could increase the length of the path but decrease the number of used edges. any help would be appreciated

Теги graph, graphs, shortest path, dijkstra

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский A.ElGamal 2015-09-04 04:01:19 621 Initial revision (published)