From 5d8dfe892a2ea89f706ee140c3bdcfd89fe03fda Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Wed, 21 Jan 2026 22:40:55 +0100 Subject: Add Redis source code for testing --- examples/redis-unstable/deps/lua/test/sort.lua | 66 ++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 examples/redis-unstable/deps/lua/test/sort.lua (limited to 'examples/redis-unstable/deps/lua/test/sort.lua') diff --git a/examples/redis-unstable/deps/lua/test/sort.lua b/examples/redis-unstable/deps/lua/test/sort.lua new file mode 100644 index 0000000..0bcb15f --- /dev/null +++ b/examples/redis-unstable/deps/lua/test/sort.lua @@ -0,0 +1,66 @@ +-- two implementations of a sort function +-- this is an example only. Lua has now a built-in function "sort" + +-- extracted from Programming Pearls, page 110 +function qsort(x,l,u,f) + if ly end) + show("after reverse selection sort",x) + qsort(x,1,n,function (x,y) return x