Graph Algorithms

Answer & solution
Official answer: 12.0 : 12.0
Our answer: 12
Without edge 3–4, the shortest route between its endpoints is 3→2→1→4 of length 5+2+5=12; the two-edge alternatives both cost 13. Any edge heavier than an alternative endpoint path cannot occur in a shortest path, since replacing it improves the route. At x=12 the edge itself ties the shortest endpoint route, so the largest integer is 12.
It suffices to compare x against the best route between its own endpoints that avoids that edge. Any shortest path using a heavier edge could be improved by substituting that alternative segment. The relevant routes from 3 to 4 have costs 13 via 1,13 via 2,12 via 2 then 1, and 18 via 1 then 2; thus 12 is the threshold. Equality is allowed because the question requires at least one shortest path, not a uniquely shortest path. At x=12, the direct edge is itself a shortest 3-to-4 path.