Can board states be transformed? | Google Interview Question