← Questions
Robot route with charging cells: fewest charges, then battery, then moves
0
I was asked this
No reports yet. Sign in to say where you were asked it.
A robot crosses a grid from S to D. Cells are . (open), # (blocked) or C (a charging cell). The battery limits how far the robot can go between charges, and a charging cell refills it.
Find a route that uses the fewest charging stops; among those, compare by battery, then by the number of moves. Explain the state you search over and why your ordering is correct. A related screen asked for the lexicographically smallest of the best routes.
No official answer yet. Write yours on the right and run it.
Nothing published yet.
Write and test your solution herePython in your browser, the question's tests level by level, saved for you.Sign in to start coding
