(4 comments) - (Post a new comment)
(Reply to this) (Thread)
(Reply to this) (Parent)(Thread)
(define (cycle! list) (define (cycle-rec! rec) (if (null? (cdr rec)) (set-cdr! rec list) (cycle-rec! (cdr rec)))) (if (not (null? list)) (cycle-rec! list))) (define list '(a b c)) (cycle! list) list => a b c a b c a b c ...
(Reply to this) (Parent)