Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
ww520
· 4mo ago · 0 comments
For small arrays that can fit in L1 cache, it's ok to do more loops. For bigger arrays, cache miss could remove all the gains.
Comments
[–]
pkhuong
4mo ago
Regardless of the array's size, the expected win from early exit on random keys is a constant number of iterations.