Python short O(n) solution


#1
class Solution:
    # @param A : list of integers
    # @return an integer
    def canJump(self, A):
        m = 0
        for i, el in enumerate(A):
            if m < i:
                return 0
            m = max(m, i + el)
        return 1