← Greedy Algorithms Quiz: all 8 questions
Greedy Algorithms Quiz · Question 7 of 8
In Gas Station, if the running tank goes negative at station i, the next candidate start is…
In Gas Station, if the running tank goes negative at station i, the next candidate start is…
- A.Station 0
- B.Station i
- C.Station i + 1
- D.The station with the most gas
Answer & explanation
Correct answer: Station i + 1
No station from the current start up to i can complete the circuit, so start after i.
Can you get the rest right without peeking?
Take the timed Greedy Algorithms Quiz quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →