|
We want to have an array which can grow in size because we don't know the
final size in advance. This is suitable for things where appending data is
needed but removing data is not needed. An example is parsing input files.
The advantage over linked list is that it uses less memory per element,
and it is faster to iterate over all elements.
BUG=chromium-os:36300
TEST=make check
Change-Id: I8b49d41e2bb3d601dba67b2871316af927825c28
Reviewed-on: https://gerrit.chromium.org/gerrit/38377
Commit-Ready: Chih-Chung Chang <chihchung@chromium.org>
Reviewed-by: Chih-Chung Chang <chihchung@chromium.org>
Tested-by: Chih-Chung Chang <chihchung@chromium.org>
|