Because if I don't test its value when the word I send finishes, it continues to add blank spaces to the string.
What does that have to do with testing the value of a char before reading it? I'm not saying don't test the value, I'm saying read the value before you test it.
You really should restructure your code. The whole deal you are doing with the words variable is predicated on all of the information arriving within a single iteration of the loop, and is a workaround to avoid writing non blocking code. Look at the psuedo code I posted earlier; no need for a delay(), and less coding.