Dynamic array: Difference between revisions

Content deleted Content added
m Reverted edits by 219.91.203.242 (talk) to last version by Icep
Line 15:
/* resize a to twice its current capacity */
a.capacity = a.capacity × 2;
/* increasing capacity often requires reallocating
memory in a different ___location; then we will need
to copy the contents to the new ___location here */
}
a[a.size] := e;