Lista de barras e imprime
Function SortIntegerList : String;
var a : Array of cardinal;
i,j : integer;
t : cardinal;
Letter : String[1];
AStr : String;
begin
// USING the simple Satolo cycle to unsort/scramble a numeric string
// Modified to scramble the letters of the Alphabet
randomize;
a := [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26];
i := length(a);
while i > 0 do
begin
dec(i);
j := randomrange(Low(a),i);
t := a[i];
a[i] := a[j];
a[j] := t;
Letter := Chr(a[i]+64);
AStr := AStr + Letter;
end;
Result := AStr;
end;
// How to use
Procedure ButtonClick(Sender: TOBject);
begin
ShowMessage('Scrambled String '+AStr);
end;
JerBear