edited by
173 views
0 votes
0 votes

An $n \times n$ binary matrix $M$ is called a NICE matrix, if each row of $M$ has exactly one non-zero element and each column also has exactly one non-zero element.

  1. Suggest a method of storing a NICE matrix in an $O(n)$ size array.
  2. Design an $O(n)$ time algorithm (in pseudocode) for computing $R=P Q$, where $P$ and $Q$ are both NICE matrices each stored in an array of size $O(n)$ as in (i).
edited by

Please log in or register to answer this question.

Related questions

0 votes
0 votes
0 answers
1
admin asked Aug 25, 2022
312 views
Consider the following state diagram of a sequential circuit, where each of a, b, c, d, e, f and g represents a state. Represent thestate diagram with minimum number of s...