Delphi Programming

Selection sort

2,919pages on
this wiki
Add New Page
Talk0 Share

Selection sort algorithm example from TThread demo of Delphi 5:

 procedure TSelectionSort.Sort(var A: array of Integer);
   I, J, T: Integer;
   for I := Low(A) to High(A) - 1 do
     for J := High(A) downto I + 1 do
       if A[I] > A[J] then
         VisualSwap(A[I], A[J], I, J);
         T := A[I];
         A[I] := A[J];
         A[J] := T;
         if Terminated then Exit;
Code Snippets
DatabasesFiles and I/OForms/WindowsGraphicsNetworkingMath and AlgorithmsMiscellaneousMultimediaSystemVCL

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Also on Fandom

Random Wiki