[CM] copier -> length of periods

Johannes Quint johannes.quint@web.de
Sun, 27 Feb 2005 14:38:26 +0100


--Apple-Mail-1-207804262
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
	charset=US-ASCII;
	format=flowed

i have the folllowing pattern:

(setf cp
  (new copier :of
      (new heap :of '(a b c)) :for (new random :of '(1 2 3)))
  )

now, when the 'for'-option of copier selects i.e. a 2,
the pattern-period contains 6 elements, i.e.:

(next cp t)
=> (b a c b a c)

but what i want, is that the repetition comes in the NEXT period,
i.e.:

(loop repeat 5 collect (next cp t))
=> ((a c b)(a c b)(c a b)(c a b)(c a b))

thanks for hints, jq

---
Johannes Quint
Rilkestr.55
D-53225 Bonn
0228 468256
johannes.quint@web.de
http://private.addcom.de/j.quint/index.htm
--Apple-Mail-1-207804262
Content-Transfer-Encoding: 7bit
Content-Type: text/enriched;
	charset=US-ASCII

i have the folllowing pattern:


(setf cp

 (new copier :of

     (new heap :of '(a b c)) :for (new random :of '(1 2 3)))

 )


now, when the 'for'-option of copier selects i.e. a 2,

the pattern-period contains 6 elements, i.e.:


(next cp t)

=> (b a c b a c)


but what i want, is that the repetition comes in the NEXT period,

i.e.:


(loop repeat 5 collect (next cp t))

=> ((a c b)(a c b)(c a b)(c a b)(c a b))


thanks for hints, jq

<italic><fontfamily><param>Helvetica</param><bigger>

---

Johannes Quint

Rilkestr.55

D-53225 Bonn

0228 468256

johannes.quint@web.de

http://private.addcom.de/j.quint/index.htm</bigger></fontfamily></italic>
--Apple-Mail-1-207804262--