HN
Hacker News
Top
New
Best
Ask
Show
Jobs
Comment by fyi1183 | Hacker News Reader
Parent
Full thread
fyi1183
·
... with a bias if X is not a power of 2.
View on HN
Retric
·
Depends on the maximum range provided. If both part's pick a X bit number then you need a power of 2. If they pick a number 1 to X then can use X.
fyi1183
·
You're right of course. Just remember to use addition mod X instead of xor in that case to combine the choices.
Reply on news.ycombinator.com