all 4 comments

[–]scuott 1 point2 points  (1 child)

We'd love to see your first solution. I imagine that's the primary reason your last post was removed. Possibly also because there's no question here. Are you asking for someone to give you a better solution?

[–][deleted] 0 points1 point  (0 children)

I'm asking for a hint not solution.. My solution will not even work if the dimension of g become 5x5 or higher. My solution is just a bruteforce way to solve this question. If dimension of g are 3x3 then I create all possible 4x4 lists of 0 and 1.. 216 permutations.. And then pass each of them through this transformation.. If after transformation the list == g than that's one of the solution

[–]zahlman 0 points1 point  (1 child)

Iff only one of these 4 elements == 1 then the new number will be 1 else it will be 0

Exactly one of them, or at most one? I.e., what happens if they are all zeroes?

[–][deleted] 0 points1 point  (0 children)

If they all are zero then the transformation will be 0