We really need a "I fucking suck at Java, please save me" master thread or something.
I need to write a program where the user inputs their full name (First and last, or first, middle and last)
They can input their name in four different ways:
First Middle Last
Last, First Middle
So I need my output to state what is the first, last, and middle if applicable. So I'm thinking the best way is to split the String, and assign String, String and String to the separate names, and use a comma (",") and space (" ") delimiters. What I don't know, is how to write it to use only the applicable delimiters, or use both, and assign the Strings to first, middle, and last based on whether comma was used or not.
So for the first input option, it would use only the space delimiter, and split the string into two; first & last.
The second input would also use only the space delimiter, and split it into three. First, middle and last.
The final two input options would use both the comma delimiter, and space delimiter, and assign String to last, and  and  to first and middle (if needed.)
Wirelessly posted (Hivemind: Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5)
I forget how to set it, but you can have multiple delimiters with multiple associated responses using scanner