To jest stara wersja strony!


import alice.tuprolog.* ;
import java.io.FileInputStream ;
 
public class Test2P {
  public static void main(String[] args) throws Exception {
    Prolog engine = new Prolog() ;
    SolveInfo info = engine.solve("append([1],[2,3],X).") ;
    System.out.println(info.getSolution()) ;
    Theory theory = new Theory(new FileInputStream("car.pl")) ;
    try {
        engine.setTheory(theory) ;
    }
    catch(InvalidTheoryException ex) {
        System.out.println("Error :/") ;
    }
    SolveInfo info1 = engine.solve("start.") ;
    System.out.println(info1.getSolution()) ;
  }
}
pl/miw/miw08_prolog_java/tuprolog.1209342339.txt.gz · ostatnio zmienione: 2019/06/27 15:59 (edycja zewnętrzna)
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0