Can you reach the last tile?
You stand on the first tile of a row. jumps[i] is the longest jump forward you may take from tile i; any shorter jump is allowed too. Return True if you can land on the last tile, otherwise False.
jumps has at least one tile and its values are non-negative. Aim for one pass and O(1) extra space.
Besides the tests, one large input (8,000 tiles) with a ~200 ms limit (scaled to your device's speed): brute force won't pass.
Examples
can_reach_end([2,0,1,0])→truecan_reach_end([1,1,0,1])→falsecan_reach_end([2,3,0,0,1])→true