[Tutor] python syntax: underscore
Michael Connors
connorsml at gmail.com
Thu Jul 12 14:04:55 CEST 2007
Hi,
I was following the thread on about the _("xx") thingy.
Since then I played around a bit with underscores at the console and it
seems to me that if you execute code with a return value but you dont save
the result, then _ is a pointer to this value.
Is that correct?
>>4
4
>>print _
4
So if I do this,
>>_ = 10
>>4
4
>>print _
10
What is this _ used for?
If I assign something to the underscore, will it cause strange things to
happen later?
(Just curiosity)
Regards,
--
Michael
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20070712/d7dc9390/attachment.htm
More information about the Tutor
mailing list