Super Simple Python


  • 0
    C
        result = False        
        i = 0
        while i <= len(bits) - 1:
            if i == len(bits) - 1:
                if bits[-1] == 0:
                    return True
            if (bits[i] == 1):
                i += 2
            else:
                i += 1
    
        return result

Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.