procedure SetLength(var X; L: LongInt);
Sets the length of a string or dynamic array.
If a dynamic array is shared with another variable, SetLength copies it only when the length changes. See Language differences compared to Delphi.