# [K (ngn/k)], 46 bytes

Created on the APL Farm with lots of input from chrispsn.

    {++(,/(.x@y)#'"-="x_y#="PNP";"_")@3\466}`c$!58

[Try it online!][ngn-0a4a4736]

[K (ngn/k)]: https://codeberg.org/ngn/k
[ngn-0a4a4736]: https://ngn.codeberg.page/k#eJxLs6rW1tbQ0dfQq3Co1FRWV9K1VaqIr1S2VQrwC1CyVopX0nQwjjExM6tNSFZRNLXg4kowsEpTUDI08lOCMwNgTBM/kwBLP/MAQz/DACM/oDgAQCoWRQ==

---

# k9 2021.03.27, <s>53</s> 52 bytes

-1 byte thanks to chrispsn!

    ++"_  ",|"_ ",,,/{.[x]#*"-="y#="PNP"}/'-2^(~=':64>)^

[Try it online][1] on kparc.io!


  [1]: https://kparc.io/k/#f%3A%2B%2B%22_%20%20%22%2C%7C%22_%20%22%2C%2C%2C%2F%7B.%5Bx%5D%23*%22-%3D%22y%23%3D%22PNP%22%7D%2F'-2%5E(~%3D'%3A64%3E)%5E%3B%20f%20%2212P4N4P9N7P1N1P2N2P%22