Message151977
For the sake of completeness: Collision-counting (with Exception) has interesting effects, too. >>> d={((1<<(65+i))-2**(i+4)): 9 for i in range(1001)} >>> for i in list(d): ... del d[i] >>> d {} >>> 9 in d False >>> 0 in d Traceback (most recent call last): File "<stdin>", line 1, in <module> KeyError: 'too many slot collisions' >>> d[9] = 1 >>> d {9: 1} >>> d == {0: 1} False >>> {0: 1} == d Traceback (most recent call last): File "<stdin>", line 1, in <module> KeyError: 'too many slot collisions' | |
| Date | User | Action | Args | | 2012-01-25 21:34:40 | fx5 | set | recipients: + fx5, lemburg, gvanrossum, tim.peters, barry, georg.brandl, terry.reedy, gregory.p.smith, jcea, mark.dickinson, pitrou, vstinner, christian.heimes, benjamin.peterson, eric.araujo, grahamd, Arfrever, v+python, alex, zbysz, skrah, dmalcolm, gz, neologix, Arach, Mark.Shannon, eric.snow, Zhiping.Deng, Huzaifa.Sidhpurwala, Jim.Jewett, PaulMcMillan | | 2012-01-25 21:34:39 | fx5 | set | messageid: <1327527279.92.0.607241526075.issue13703@psf.upfronthosting.co.za> | | 2012-01-25 21:34:39 | fx5 | link | issue13703 messages | | 2012-01-25 21:34:39 | fx5 | create | | |