Chess is an indoor and competitive game played between two players. It is being played in tournaments, online or at home. The origin of chess is traced to India of the 6th century during the Gupta Empire. The military had four divisions known as "infantry", "cavalry", "elephant" and "chariot". These names are represented in the chess game as: pawn, knight, bishop and the rook respectively. In the 9th century, the game was introduced to Western Europe and Russia.The chess board is made up of 64 squares (eight rows and eight columns) and the colors of the squares alternate (dark and light squares). The pieces which are comprised of a king, a queen, two rooks, two bishops, two knights, and eight pawns are in sets black and white. To start the game, white moves first. The pieces are moved one at a time to an occupied square by an opponent's piece, thereby removing it from play or to a square that is not occupied. However, two pieces are moved simultaneously when castling.Each chess piece has its own style of moving. The pawn moves one or two steps forward to an unoccupied square but one forward diagonal step to an occupied square. The Knight moves in "L" pattern. The bishop moves diagonally. The rook moves horizontally or vertically with as many steps as possible. The queen moves in all directions covering as many squares as possible. And the king moves one step at a time in all directions.The king is permitted to make a move called castling. The king makes two squares towards the rook of the same color and the rook moves onto the square over which the king crossed. The following are the prerequisites to castling:
- The king and the rook must be on the same color
- The king and the rook involved in the castling may not have been previously moved
- There must be no pieces between the king and the rook
- The king may not currently be in check.Pawns could be promoted to any of the