ronin/examples/archives/random.file.lisp
Devine Lu Linvega 39b2e558bd Moving examples
2019-07-22 15:36:16 +09:00

14 lines
209 B
Common Lisp

; filesystem
; get files
(def files
(dir
(dirpath)))
; pick a random file
(def random-index
(floor
(random
(len files))))
; print random file name
(echo
(get files random-index))