Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
dllu
on April 22, 2013
|
parent
|
context
|
favorite
| on:
Weighted/Biased Random Number Generation with Java...
For method 2, if you precompute the cumulative distribution function, you can do a binary search which is only O(log N) instead of O(N).
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: