They're subtracting 1 because of the nature of the while loop - it will stop looping when index is 1 more than the length of the string, because it is there that it finds no character. However, if you started indexing at 0, this would correct the issue, because you're essentially not counting...