Y
Hacker News
new
|
ask
|
show
|
jobs
by
layer8
21 days ago
It works perfectly fine for size = 0?
1 comments
xigoi
20 days ago
They meant x = 0.
link
layer8
20 days ago
Not sure if they meant that, since the “awful” was referring to the original loop that had no x, but the generic solution in that case is:
for (size_t i = size; i—- > x;)
link