Given a matrix Z, extract the rows that do not have all-equal values (e.g. keep [2, 2, 3], drop [5, 5, 5]). Return the filtered rows.
Z
[2, 2, 3]
[5, 5, 5]
Input
[[1 1 1] [1 2 3] [4 4 4] [5 6 5]]
Output
[[1 2 3] [5 6 5]]
This one's part of Premium. Unlock the full NumPy track plus every other premium problem on the site.
solve(...)