Split by XML

I'm sitting on my hands to keep myself from writing it for you...

For starters, why don't you leave XML aside temporarily and write a program to parse
((A B) C (D E)) into


Don't use SPLIT; just a FOR loop that looks at each character and does something special if it's ( or ).

But make sure you call the same procedure to parse the (A B) etc.