Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
yangmaster
· 8y ago · 0 comments
Fisher-Yates shuffle. An elegant and surprisingly intuitive O(n) algorithm that doesn't take up extra memory.
Comments
[–]
malingo
8y ago
Check out Sattolo's algorithm as well. Good writeup here:
https://danluu.com/sattolo/