We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
This is a relatively sparse matrix, so we might be able to solve it directly.
Find any row or column that has only one non-zero value. The remaining zeros nullify any sub-matrix they might multiply, so the determinant must go through that value. Accordingly, we can zero out the rest of the column or row (note the reversal of terms) where a value is the only non-zero in its column or row. (There are two such.)
Iterate #1 as far as possible. (This isolates a third row & column)
The determinant of the remaining matrix is (relatively) easy to compute.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Determinant of the matrix #1
You are viewing a single comment's thread. Return to all comments →
This is a relatively sparse matrix, so we might be able to solve it directly.