Binary Game

Alice and Bob love to play with numbers, one day they found an array with $N$ integers consisting of only $0$ and $1$. Alice wants to play a range query game with Bob. Alice will give Bob a range from $L$ to $R$. Bob needs to tell her who wins $0$ or $1$. For $0$ to win, the occurrence of $0$ in the given range must be strictly greater than that of $1$.

This is a companion discussion topic for the original entry at