On 15/6/2013 12:54 μμ, Lele Gaifax wrote:
Nick the Gr33k <supp...@superhost.gr> writes:

On 15/6/2013 8:27 πμ, Larry Hudson wrote:
Also they do NOT return "a variable's truthy value", they return the
variable itself.

No, as seen from my above examples, what is returned after the expr
eval are the actual variables' values, which in turn are truthy, *not*
the variable itself.

In the context we are talking about, "the variable itself" has the very
same meaning as "the actual variable value":

Are there cases that a variable and the variable's value cosidered to be 2 different things?

mylist = ['foo']
emptylist = []
result = emptylist or mylist

result = mylist (since its a no-emoty list)

result.append('bar')
result is mylist
True

Never seen the last statement before. What does that mean?
result is mylist ????


--
What is now proved was at first only imagined!
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to