/* This files implements an interpreter for a BASIC-like language */ //import jbclasses.*; public class jbinterp { /* label BEGIN; print "Hello\n"; goto BEGIN; static prog p0 = new prog( cons(new labelst("BEGIN"), cons(new printst(new strexp("Hello!\n")), cons(new gotost("BEGIN"), null)))); */ public static void main(String[] args) { try { parser theparser = new parser(); // create parser object prog theprogram; // abstract syntax tree theprogram = (prog) theparser.parse().value; theprogram.run(); // run the program! } catch (Exception e) {} // System.out.println("\nProgram Terminated Successfully."); } } // end of class jbinterp