101 reputation
1
bio website
location
age
visits member for 8 months
seen Aug 6 '13 at 22:54

Aug
2
awarded  Supporter
Aug
2
comment creating a small number from a cryptographically secure random string
Never mind.. floor(s/k)*k == floor(256/140)*140 == 140 - not 1.
Aug
2
comment creating a small number from a cryptographically secure random string
i don't see how this is supposed to work. Let's say k = 140, n = 256 and the first x = 139. it'd loop at least once then per pastebin.com/zHxm9LD6. it doesn't seem like it should be looping at all, however, since 139 < 140...