Hey. So I'm trying to get a string from the user and then return the number of characters in it to the user. Then i want to use a separate function to return the same inputted string with no spaces. The first function runs just fine, but then when the second one is called, it waits for a new input, which is the first problem. I don't know if the second problem will be fixed by the first solution, but the second problem is that no matter what I input for the second function, it returns "yG". All help is appreciated.
In your removeSpaces function you declare an array (illegally, I might add). You don't put anything in that array, so the array contains junk, therefore when you output the array, you get junk.
First, of course, you ask the user for a new string on line 35. Getting rid of line 35 if you don't want new input would be advised. Passing arguments instead of using global data would probably also be advised.