CSPTop - } // Main method public static void main(String...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
package CSP; /** * Title: CSPTop * Description: Top-level class for CSP * Copyright: Copyright (c) 2005 * Company: MIT * @author Andreas Hofmann * @version 1.0 */ public class CSPTop { static CSP_rep current_csp = null; public CSPTop() { current_csp = new NQueens(4); // Gets rough at about 18 queens. current_csp.initialize();
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: } // Main method public static void main(String args) { new CSPTop(); current_csp.print(); System.out.println("\nSolving"); boolean solve_res = current_csp.backtrack(); System.out.println("Consistent result = " + solve_res); System.out.println("Solution:"); current_csp.print(); } }...
View Full Document

Ask a homework question - tutors are online