+1 vote
in Data Structures & Algorithms I by (110k points)
The matrix contains m rows and n columns. The matrix is called Sparse Matrix if ________

(a) Total number of Zero elements > (m*n)/2

(b) Total number of Zero elements = m + n

(c) Total number of Zero elements = m/n

(d) Total number of Zero elements = m-n

I'm obligated to ask this question of Arrays Types topic in chapter Arrays Types of Data Structures & Algorithms I

I have been asked this question in an online interview.

1 Answer

+1 vote
by (408k points)
selected by
 
Best answer
Correct answer is (a) Total number of Zero elements > (m*n)/2

For explanation: For matrix to be Sparse Matrix, it should contain Zero elements more than the non-zero elements. Total elements of the given matrix is m*n. So if Total number of Zero elements > (m*n)/2, then the matrix is called Sparse Matrix.

Related questions

Welcome to TalkJarvis QnA, a question-answer community website for the people by the people. On TalkJarvis QnA you can ask your doubts, curiosity, questions and whatever going in your mind either related to studies or others. Experts and people from different fields will answer.

Categories

...