Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Search
⌘K
Get Premium
Leetcode 2699. Modify Graph Edge Weights
Given an undirected weighted graph where some edges have weight -1 (modifiable) and others are fixed, assign positive integer weights (in [1, 2e9]) to the -1 edges so that the shortest-path distance from source to destination equals a given target, or report impossibility. The core challenge is finding weight assignments that exactly match the target shortest-path length while respecting the fixed edges and shortest-path structure.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.