Hacker News new | ask | show | jobs
by murderfs 958 days ago
Inserting an element in an array is something along the lines of memmove(arr + idx + 1, arr + idx, (length - idx) * sizeof(*arr)); arr[idx] = foo;