灯下 登录
计算机科学 / SICP / 4.2.3 Streams as Lazy Lists

Exercise 4.34 · 习题

Exercise 4.34: Modify the driver loop for the

evaluator so that lazy pairs and lists will print in some reasonable way.

(What are you going to do about infinite lists?) You may also need to modify

the representation of lazy pairs so that the evaluator can identify them in

order to print them.

练习 4.34:修改求值器的驱动循环,使惰性序对和惰性表能以某种合理的方式打印输出。(对于无穷表,你打算怎么处理?)你可能还需要修改惰性序对的表示方式,以便求值器能识别它们并加以打印。