<html><body>
<p><b><u>print function: built-in space between string and variable:</u></b><br>
<br>
The below python code, <br>
<br>
<b><i>length = 5</i></b><br>
<b><i>print('Length is', length)</i></b><br>
<br>
gives an output of<br>
<br>
<b><i>Length is 5</i></b><br>
<br>
Even though we have not specified a space between 'Length is' and the variable length, Python puts it for us so that we get a clean nice output and the program is much more readable this way (since we don't need to worry about spacing in the strings we use for output). This is surely an example of how Python makes life easy for the programmer.<br>
<br>
<b><u>input function: built-in space between string and user-input:</u></b><br>
<br>
However, the below python code,<br>
<br>
<b><i>guess =  int(input('Enter an integer'))</i></b><br>
<br>
gives an output of <br>
<br>
<b><i>Enter an integer7</i></b><br>
<br>
[Note: Assume 7 is entered by the user.]<br>
<br>
<b>Suggestion: </b>Similar to the printf function, for the input function also, it will be nice to have the Python put a space between string and user-input, so that the output in the above case will be more readable as below.<br>
<br>
<b><i>Enter an integer 7</i></b><br>
<br>
Thanks and Regards,<br>
Suriaprakash M,<br>
Principal Engineer - Software,<br>
Standard Microsystems India Pvt. Ltd.,<br>
Module 1, 4th Floor, Block A, SP Infocity,<br>
#40, MGR Salai, Perungudi,<br>
Chennai - 600 096, Tamil Nadu, INDIA.<br>
Email: Suriaprakash.Mariappan@smsc.com<br>
Mobile :+919381453832<br>
Skype ID: msuriaprakash</body></html>