No need for DP O(n) time with O(1) space complexity


#1

No need to evaluate all possible jump, think how long it can jump from one point…