## XOR of a submatrix queries

Given an N * N matrix and q queries, each containing position of top-left and bottom-right corner of a rectangular sub-matrix, the task is to… Read More »

- Rotate a matrix by 90 degree in clockwise direction without using any extra space
- Matrix Chain Multiplication (A O(N^2) Solution)
- Find the number of distinct islands in a 2D matrix
- Minimum steps to reach any of the boundary edges of a matrix | Set-2
- Minimum steps to reach any of the boundary edges of a matrix | Set 1
- Kruskal's Algorithm (Simple Implementation for Adjacency Matrix)
- Print matrix in snake pattern from the last column
- Count the number of ways to traverse a Matrix
- Final cell position in the matrix
- Find number of Positional Elements
- Find number of cavities in a matrix
- Minimum cost to buy N kilograms of sweet for M persons
- Minimum distance to the end of a grid from source
- Interchange elements of first and last columns in matrix
- Print the matrix diagonally downwards
- Printing Matrix Chain Multiplication (A Space Optimized Solution)
- Check if the given chessboard is valid or not
- Find Nth term (A matrix exponentiation example)
- Program to print Spiral Pattern
- Find alphabet in a Matrix which has maximum number of stars around it
- Prim's Algorithm (Simple Implementation for Adjacency Matrix Representation)
- Minimum odd cost path in a matrix
- Find the largest area rectangular sub-matrix whose sum is equal to k
- Print all paths from top left to bottom right in a matrix with four moves allowed
- Find maximum path length in a binary matrix
- Print numbers in matrix diagonal pattern
- Minimum sum falling path in a NxN grid
- Print matrix in zig-zag fashion from the last column
- Unique paths covering every non-obstacle block exactly once in a grid
- Magical Pattern

Given an N * N matrix and q queries, each containing position of top-left and bottom-right corner of a rectangular sub-matrix, the task is to… Read More »

Given a NxN 2-D matrix, the task to find the sum of all the submatrices. Examples: Input : arr[] = {{1, 1}, {1, 1}}; Output… Read More »

Given a spirally sorted matrix with N * N elements and an integer X, the task is to find the position of this given integer… Read More »

Given the source point and the destination point of the path and two integers x and y. The task is to check whether it is… Read More »

Given an N x N matrix and two integers S and K, the task is to find whether there exists a K x K sub-matrix… Read More »

Given the position of a Bishop on an 8 * 8 chessboard, the task is to count the total number of squares that can be… Read More »

Given the position of a Bishop and a Pawn on a 8 * 8 chessboard, the task is to check whether the Bishop can take… Read More »

Given a matrix of size NxN. The task is to count the number of pair of indices (i, j) such that the sum of j-th… Read More »

Given an N * N board which is initially empty and a sequence of queries, each query consists of two integers X and Y where… Read More »

Given 9 elements in a 3 x 3 matrix where the value of diagonals are 0. We need to find the values in diagonal to… Read More »

Given a grid grid[][] with 4 types of blocks: 1 represents the starting block. There is exactly one starting block. 2 represents the ending block.… Read More »

Given a N x M matrix which represents the number of rows and number of columns respectively. Each cell of a matrix is occupied by… Read More »

Given an integer K and a matrix of N rows and M columns, the task is to find the minimum number of operations required to… Read More »

Given a NxN matrix and an integer X. The task is to remove X rows and X columns from the NxN matrix. Remove first X… Read More »

Given a matrix mat[][] containing the characters [1 – 9], P and * where P is a person and * is an empty space. An… Read More »