protected override void InternalVisualize(TestCaseUI ui) { ui.Rect(r1, neutralPen); ui.Rect(r2, neutralPen); ui.Log("r1: {0}", r1); ui.Log("r2: {0}", r2); ui.Log("Solution: "); ui.Log(" intersected: {0} {1}", intersectedAnswer, intersected != intersectedAnswer ? "wrong!" : ""); ui.Log(" intersection square: {0} {1}", intersectionSquareAnswer, intersectionSquare != intersectionSquareAnswer ? "wrong!" : ""); ui.Log(" index of inner rectangle: {0} {1}", indexOfInnerRectAnswer, indexOfInnerRectangle != indexOfInnerRectAnswer ? "wrong!" : ""); }
private void DrawWall(TestCaseUI ui, int x, int y) { var x1 = x*cellSize - 100; var y1 = y*cellSize - 100; var x2 = (x + 1) * cellSize - 101; var y2 = (y + 1) * cellSize - 101; ui.Rect(new Rectangle(x1, y1, cellSize, cellSize), neutralPen); ui.Line(x1, y1, x2, y2, neutralPen); ui.Line(x1, y2, x2, y1, neutralPen); }