String treeString = "(6 (5 (1) (2)) (3))";
Scanner sc = new Scanner(treeString);
try{
sc.findInLine("(\\() (\\d+) ");
}
catch (java.lang.IllegalStateException e) {System.out.println("caught");}
catch (Throwable e) {System.out.println("caught");
Neither of those catch statements work singly, together, or at all. My program always exits on a stack trace of the InvalidStateException. help?

New Topic/Question
Reply



MultiQuote




|