@Test public void testSolveNQueens3() { ArrayList<String[]> result = s.solveNQueens(4); for (String[] sa : result) { System.out.println(Arrays.asList(sa)); } assertNotNull(result); assertTrue(result.size() == 2); }
@Test public void testSolveNQueens4() { ArrayList<String[]> result = s.solveNQueens(9); for (String[] sa : result) { System.out.println(Arrays.asList(sa)); } assertNotNull(result); assertTrue("number of distinct solutions " + result.size(), result.size() == 352); }
@Test public void testSolveNQueens1() { ArrayList<String[]> result = s.solveNQueens(0); assertNotNull(result); assertTrue(result.size() == 0); }