Printing out ... depending on character count of previous words entered.
Ok I have a program which allows the user to input two words, I then use the length() function to find out how many characters are in the words. Is it possible to add this two together and take it away from say 70 and then with the remaining character stick it between the two words.
Example:
First word = Hello
Second word = Goodbye
5+7 = 12
70 - 12 = 58
So it would output,
Hello............................................. .............Goodbye
The dots in the middle would vary depending on the length of the two words entered. I don't want to know how to code this just how I would work out how to calculate how many dot's would be needed and then how to print that out.
Thanks