05-05-2021, 03:02 AM
Another problem with your code was that it always allowed placement on a perimeter location, -- But the rule is that it must be connected to EMPTY perimeter locations, so just being on the perimeter doesn't necessarily count as a legal move.