Added one more loop and returning the variable

The loop is adding the characters to make the input unreadable.