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.
Flipping the Matrix
Flipping the Matrix
Sort by
recency
|
283 Discussions
|
Please Login in order to post a comment
I just ran into this problem on a test that I had 24 min to solve. I didn't solve it in time. My brain spun to even see the pattern needed beyond getting the max value. So I went and learned the trick online... https://youtu.be/4rin1enhuQQ?si=By2NI2du9ZO6qtf7
https://github.com/SWT92/hackerrank_flipmatrix
My answer seems different from the originator, anyone got 483 the following matrix?
this problem deep fried my brain
Symmetry: We exploit the symmetry of the 2Nx2N matrix to reduce calculations. Maximum value: For each position inside N x N, we find the maximum among the number and its three symmetric counterparts. Summation: The sum of these maximum values gives us the desired result.