Originally posted by Styxx
Yeah, that line should have an escape charachter, or use double quotes... but that would be a compile problem, not a runtime one. What exactly is it that you're trying to do anyway...?
That's a miss-type, BTW - I missed the \ in the post

prolog tree parser... see Question 5;
http://www.cs.strath.ac.uk/teaching/ug/classes/52.222/222_P_2.htmlBasically, to break a prolog tree definition ala tree(nil,a,nil).
(left, middle, right)
into tokens, and then to feed the tokens into a Binary Tree and display it.
(inc. nested trees, eg tree(tree(nil,b,nil),a,nil) )
I'm trying to split it into tokens, either strings (eg nil, node data) or single characters, like left and right brackets..... i have a StringTokenizer method written earlier, but this was a lot simpler. Plus my method removed all the punctuation - just kept letters - which I want to keep here, so I replaced it.
EditStringtokenizer won't work b- or it'll be a ***** - and I can't use linereader cos it runs over mutliple lines and I don't want to do the workaround code just yet (I need to code in a line seperator later on, because of Unix string buffer restrictions). It seperates the tokens fine, it's just getting out the damn character ones that's the problem.