Author methane
Recipients Dmitry Rubanovich, methane, rhettinger, serhiy.storchaka, xiang.zhang
Date 2017-06-16.00:39:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1497573565.1.0.173621171032.issue30671@psf.upfronthosting.co.za>
In-reply-to
Content
Firstly, do you understand the lookup without perturb?
It's documented here:
https://github.com/python/cpython/blob/258bfc462b1e58689b43f662a10e44ece3a10bef/Objects/dictobject.c#L161-L182

>>> n = 0; L = []
>>> for i in range(16):
...   L.append(n)
...   n = (n*5+1)%8
... 
>>> L
[0, 1, 6, 7, 4, 5, 2, 3, 0, 1, 6, 7, 4, 5, 2, 3]

>>> n = 0; L = []
>>> for i in range(16):
...   L.append(n)
...   n = (n*2+1)%8
... 
>>> L
[0, 1, 3, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7]

So you can't use 2.
History
Date User Action Args
2017-06-16 00:39:25methanesetrecipients: + methane, rhettinger, serhiy.storchaka, xiang.zhang, Dmitry Rubanovich
2017-06-16 00:39:25methanesetmessageid: <1497573565.1.0.173621171032.issue30671@psf.upfronthosting.co.za>
2017-06-16 00:39:25methanelinkissue30671 messages
2017-06-16 00:39:24methanecreate