change judge to take in actual cells instead of cell locations and a grid