---------- Forwarded message ----------
From: dean <deangwillia...@gmail.com>
Date: 6 January 2017 at 08:50
Subject: automatically generating test data
To: picolisp@software-lab.de

Is this the best way of automatically generating a list of ("aaaa" "bbbb"

(de mk_Ltest_data (Start_x Eles Ele_chars)
   (setq L (range Start_x (- (+ Start_x Eles) 1)))
   (setq L2 (mapcar 'char L))
   (setq L3 NIL)
   (for X (range 1 Ele_chars)
      (setq L3 (append L3 L2)) )
   (setq L4 (sort L3))
   (setq L5 (by name group L4))
   (setq L6 (mapcar 'pack L5)) )

: (setq *Ltest_data (mk_Ltest_data 97 26 4)

-> ("aaaa" "bbbb" "cccc" "dddd" "eeee"

Reply via email to