You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
459 B
16 lines
459 B
|
|
Exercise 3.50: Complete the following
|
|
definition, which generalizes stream-map to allow procedures that take
|
|
multiple arguments, analogous to map in 2.2.1,
|
|
Footnote 78.
|
|
|
|
|
|
(define (stream-map proc . argstreams)
|
|
(if (⟨??⟩ (car argstreams))
|
|
the-empty-stream
|
|
(⟨??⟩
|
|
(apply proc (map ⟨??⟩ argstreams))
|
|
(apply stream-map
|
|
(cons proc
|
|
(map ⟨??⟩
|
|
argstreams))))))
|
|
|