trying to split a char

PaulS- that worked perfectly, thank you.

PeterH- I did not use the scanf() because I have read here (and elsewhere) that it is not a wise thing to do. I don't know exactly why but I am sure there is good reason why people caution against its use. The second example uses a char array and I didn't have an array so I was not able to make it work.