There are total 64 squares in the chess board. 8 squares on the diagonal lines, 7 squares on each consecutive side of diagonal line, 6 on next to consecutive line of diagonal line and so on. ∴ Number of ways =[(3C3+4C3+5C3+6C3+7C3)×2+8C3]×2 =392