uses Types, Generics.Collections;
var
a: TIntegerDynArray;
begin
a := TIntegerDynArray.Create(5, 4, 3, 2, 1);
TArray.Sort<Integer>(a);
end;