Solving a Matrix Bitflip Puzzle