5. Given a 1 dimensional board. Each cell is marked with 0 or 1.For example:
Now suppose moving a chess on this board, subject to thefollowing rules:
The chess starts at rightmost cell of the board (marked aspurple in the above example).
Each time, the chess can move to the cell that is 3 or 4locations to its left. But at any time, a chess can only be puttedon a ‘0’ cell.
We can assume that rightmost and the leftmost cell has value‘0’.
The goal is to determine whether we can move the chess to cellindex 0. (Marked as green
OR
OR