Turning Corners
JavaScript
You are given a matrix of coins showing either heads or tails. A move consists of turning over four coins at the corners of a rectangle, i.e. (a,b), (a,y), (x,b), and (x,y), where 0≤a
Southeast coin: x:
y:
from heads to tails
Northwest coin: a:
b:
both a < x and b < y