diff options
| author | ame <[email protected]> | 2023-10-18 16:30:38 -0500 |
|---|---|---|
| committer | ame <[email protected]> | 2023-10-18 16:30:38 -0500 |
| commit | 034f54b14416dd411fbd204f8b5465b8bc462b76 (patch) | |
| tree | 6a551b9b4633f2570159eeb83a8f8ac9e1019100 /s.lua | |
| parent | b137acbcb983359568c0b9b2851ef7bbba9617b7 (diff) | |
md5 and sorting improvments
Diffstat (limited to 's.lua')
| -rw-r--r-- | s.lua | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -3,13 +3,14 @@ local a = llib.array local tab = {} math.randomseed(os.time()) -for i=1,5 do - table.insert(tab,math.random(1,999));-- + math.random(1,999)); +for i=1,9999999 do + table.insert(tab,i);--math.random(1,10));-- + math.random(1,999)); end -local l1 = a.bogosort(tab) - -for l,i in pairs(llib.array.reverse(l1)) do - print(i) +local l1 = a.shellsort(tab) +print(a.sindex(l1,999)); +--print(a.index(l1,1)) +for l,i in pairs(l1) do + --print(i) end |
