Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
10
Task/Perfect-shuffle/PicoLisp/perfect-shuffle.l
Normal file
10
Task/Perfect-shuffle/PicoLisp/perfect-shuffle.l
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
(de perfectShuffle (Lst)
|
||||
(mapcan '((B A) (list A B))
|
||||
(cdr (nth Lst (/ (length Lst) 2)))
|
||||
Lst ) )
|
||||
|
||||
(for N (8 24 52 100 1020 1024 10000)
|
||||
(let (Lst (range 1 N) L Lst Cnt 1)
|
||||
(until (= Lst (setq L (perfectShuffle L)))
|
||||
(inc 'Cnt) )
|
||||
(tab (5 6) N Cnt) ) )
|
||||
Loading…
Add table
Add a link
Reference in a new issue