# Tag Archives: chessboard-problems

Given a N x N chessboard with a Knight initially standing on the Xth row and Yth column, the task is to print all possible… Read More
Given the current position of a Knight as (i, j), find the count of different possible positions visited by a knight after N moves (in… Read More
Given integers current_row and current_col, representing the current position of a Rook on an 8 × 8 chessboard and two more integers destination_row and destination_col… Read More
Given a 2D array knights[][] of size N * 2, with each row of the form { X, Y } representing the coordinates of knights,… Read More
Given a 2D array queens[][] consisting of coordinates of N queens in an 8 * 8 chessboard and an array king[] denoting the coordinates of… Read More
Given two integers N and M denoting the dimensions of a chessboard, and two integers X and Y denoting the King’s position, i.e. the cell… Read More
Given an integers N such that there is a chessboard of size N*N and an array pos[][] of K pairs of integers which represent the… Read More
Given two integers N, M denoting N×M chessboard, the task is to count the number of ways a knight can reach (N, M) starting from… Read More
Given an integer N, the task is to construct a matrix M[][] of size N x N with numbers in the range [1, N^2] with… Read More
The N Queen is the problem of placing N chess queens on an N×N chessboard so that no two queens attack each other. For example, the… Read More
Given a matrix board[][] consisting of the characters K or k, Q or q, B or b, N or n, R or r, and P… Read More
Given an integer N and an array arr[] of positions which denotes the positions of already placed non-attacking rooks, the task is to find the… Read More
Puzzle: For each of the following chess pieces, find the minimum number of colors needed to color an N x N chessboard, such that no… Read More
Prerequisite: graphics.h, How to include graphics.h in CodeBlocks? In Computer Graphics, we use graphics.h which provide direct functions to draw different coordinate shapes(like circle, rectangle… Read More
Given an integer N denoting a N * N chess-board, the task is to count the number of ways to place two queens on the… Read More