A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2005-September/056012.html below:

[Python-Dev] Replacement for print in Python 3.0

[Python-Dev] Replacement for print in Python 3.0Ron Adam rrr at ronadam.com
Fri Sep 2 02:30:31 CEST 2005
Jim Jewett wrote:
>
>>Another real problem with print is that, while the
>>automatic insertion of spaces is nice for beginners,
>>it often gets in the way, and what you have to do to 
>>avoid this is pretty nasty: either drop print altogether 
>>in favor of sys.stdout.write(), or use string concatenation
>>or a format string, assuming you have all the pieces
>>available at the same time (which often you don't).
> 
> I usually take "I need to get rid of spaces" as an indication
> that I care about exact (not just readable, but exact) 
> formatting, and *should* use either write or a format string 
> (possibly waiting to collect the data).
> 
> Putting the spaces back in (without a format string) would 
> be even worse.  Charles Cazabon's pointed out that it *could*
> be as simple as
> 
>     writeln(' '.join( ... ))

Why not just offer an addition method ?

examine(x,y,z)   # print with spaces

Or some other suitable name.

Cheers,
Ron




More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4