2297. Jump Game VIII
Current Step Explanation
Click 'Next' to start the algorithm...
incst Stack (Find next >= element)
Stores indices, corresponding values are decreasing
decst Stack (Find next < element)
Stores indices, corresponding values are increasing
DP Array (Min cost to reach index i)
C++ Implementation
Live
Trace