Originally Posted by
Duoas
Ah, the loop ends at the space because the string ends at the space. scanf stops reading input at spaces. So when you enter "1234 432" the userString gets "1234", and " 432" is left waiting to be read.
If you want to get a string from the user try using fgets().
Good luck.
Thank you! I never would have figured that out. It all works the way it should now.