I want to make an input stream parser capable of handling input in any of the following forms:
x y z
x,y,z
x, y, z
(x,y,z)
(x, y, z)
Is there a clever way to do this? Or do I have to check the first character, if it is '(' then do one thing, if it is not then read a double, then check if the next character is a ',', etc etc.
Is there a robust way to handle these types of inputs?
Thanks,
Dave