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/2002-November/030356.html below:

* (and **?) in assignments

[Python-Dev] Half-baked proposal: * (and **?) in assignments [Python-Dev] Half-baked proposal: * (and **?) in assignmentsMartin v. Loewis martin@v.loewis.de
23 Nov 2002 10:25:35 +0100
Brian Quinlan <brian@sweetapp.com> writes:

> Need is a bit too strong. But which do you like better:
> 
> year, month, day = time.localtime()[0:3]
> 
> or 
> 
> year, month, day, *dummy = time.localtime()

lttime = time.localtime()
year = ltime.tm_year
month = ltime.tm_mon
day = ltime.tm_mday

Readability counts.

Actually, you may just avoid the assignments altogether, and just use
the named fields.

Regards,
Martin



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