Home

Bruno Desthuilliers wrote:
> First point is that Python has no "variable interpolation".

If you squint, it kind of does*:

>>> print '%(language)s has %(#)03d quote types.' % \
{'language': "Python", "#": 2}
Python has 002 quote types.

You might think if the dict as a name space and the formatting operation
as performing interpolation--but this take on formatting might be a stretch.

James

* http://docs.python.org/lib/typesseq-strings.html

previous
next

Re: Dispatching default application for file, cross platform.
Memory Leak with Tkinter Canvas (Python 2.5 Win32)
Re: client server framework
Re: An Editor that Skips to the End of a Def
Re: your opinion on book "Foundations of Python Network Programming"?
Niechciane i Zapomniane
Mam Marzenie
Nasze Dzieci
Podaruj Zycie
Fundacja Hobbit