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.
The editorial is slightly deceptive, in that its solution hides how dependent the runtime is on the size of the elements of the matrix are. I also found another solution which trades dependence on the element size for a heavier dependence on the dimensions of the matrix. Also, Spirya below is right that there are test cases with extra spaces, which lead to runtime errors (I got errors for 11 and 12). I hope the problem writer corrects this.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Largest Non-Coprime Submatrix
You are viewing a single comment's thread. Return to all comments →
The editorial is slightly deceptive, in that its solution hides how dependent the runtime is on the size of the elements of the matrix are. I also found another solution which trades dependence on the element size for a heavier dependence on the dimensions of the matrix. Also, Spirya below is right that there are test cases with extra spaces, which lead to runtime errors (I got errors for 11 and 12). I hope the problem writer corrects this.