Contents
Discussion
Perl coders are proud that Perl's motto is "There's more than one way to do it."
In comparison, Python is sometimes stereotyped as "There's only one way to do it", but this is of course not true. The Zen of Python, accessed via
import this
includes the maxims:
Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.
If the implementation is hard to explain, it's a bad idea.
There should be one-- and preferably only one --obvious way to do it.
The net effect is that there is a limited set of good solutions for a given problem, and users are strongly encouraged to use them.
While Python attempts to discourage bad practices, and its indentation-based block structure and limited anonymous blocks (lambdas) make certain techniques difficult, it is possible to produce many more bad solutions than good for a given problem.
Please Feel Free to add/reorder/reallocate examples.
The Problem
Your signature block (up to four lines of 78 characters each) needs code that prints "Just another Pythoneer".
The Limited Set of Good Solutions
1 print "Just another Pythoneer"
(Though someone may point out that as a Python user following correct Pythonic practice, you are more correctly a Pythonista... and give you a brief 6000 word essay on the historical debate over the naming of Python Users and the etymology of the root Python and the stem -ista... and advise you against using the combination in an impromptu Spanish examination)
The Larger Set of Not-So-Good Solutions
Normal Printing/Concatination
1 print "Just", "another", "Pythoneer"
1 import sys; sys.stdout.write("Just another Pythoneer\n")
Substitution
1 print '''%s %s %s''' % ("Just", "another", "Pythoneer")
