A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/attachments/20120308/d58e35af/attachment.html below:

On Thu, Feb 9, 2012 at 5:18 PM, Guido van Rossum <span dir="ltr">&lt;<a href="mailto:guido@python.org" target="_blank">guido@python.org</a>&gt;</span> wrote: <div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="gmail_quote"><div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="gmail_quote">


<div>A dictionary would (then) be a SET of these. (Voila! things have already gotten simplified.)</div></div></blockquote></div><div><br>Really? So {a:1, a:2} would be a dict of length 2? </div></div></blockquote><div><br>

</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="gmail_quote"><div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">

<div class="gmail_quote"><div>  Eventually, I also think this will seque and integrate nicely into Mark Shannon&#39;s &quot;shared-key dict&quot; proposal (PEP 412).</div>

<div><br></div></div></blockquote></div></div></blockquote><div><br></div><div>I just noticed something in Guido&#39;s example.  Something gives me a strange feeling that using a variable as a key doesn&#39;t smell right.  Presumably Python just hashes the variable&#39;s id, or uses the id itself as the key, but I wonder if anyone&#39;s noticed any problems with this, and whether the hash collision problems could be solved by removing this??   Does anyone even use this functionality -- of a *variable* (not a string) as a dict key?</div>


<div><br></div><div>mark</div></div>

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