24 lines
331 B
Scheme
24 lines
331 B
Scheme
|
|
||
|
(define l1 (list-n 500))
|
||
|
|
||
|
(define access-list
|
||
|
(lambda (l n)
|
||
|
(if (zero? n) l
|
||
|
(access-list (cdr l) (- n 1)))))
|
||
|
(set-cdr! (access-list l1 250) '())
|
||
|
|
||
|
(define l2 (list-n 500))
|
||
|
|
||
|
(define vectors
|
||
|
(lambda (mx)
|
||
|
(map (lambda (n) (make-vector n n))
|
||
|
(list-n mx))))
|
||
|
|
||
|
(vectors 100)
|
||
|
|
||
|
(list-n 1000)
|
||
|
|
||
|
(vectors 200)
|
||
|
|
||
|
|