Question: Question 1 Given a boolean matrix mat [M][N] of size M X N, modify it such that if a matrix cell mat[i][j] is 1
![Question 1 Given a boolean matrix mat [M][N] of size M X](https://dsd5zvtm8ll6.cloudfront.net/questions/2024/08/66b2198db2433_1722947980392.jpg)
![N, modify it such that if a matrix cell mat[i][j] is 1](https://dsd5zvtm8ll6.cloudfront.net/questions/2024/08/66b219af78f16_1722948014472.jpg)

Question 1 Given a boolean matrix mat [M][N] of size M X N, modify it such that if a matrix cell mat[i][j] is 1 (or true) then make all the cells of ith row and jth column as 1. PRACTICE NOW Question 2 Given a 2D array, print it in spiral form. Question 3 Transpose of a matrix is obtained by changing rows to columns and columns to rows. In other words, transpose of A[N][M] is obtained by changing A[i][j] to A[j][i]. Question 4 Given a 2D grid of characters and a single word/an array of words, find all occurrences of the given word/words in the grid. A word can be matched in all 8 directions at any point. Word is said to be found in a direction if all characters match in this direction (not in zig-zag form). The 8 directions are, Horizontally Left, Horizontally Right, Vertically Up, Vertically Down and 4 Diagonal directions.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
