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.
23 lines
414 B
23 lines
414 B
|
|
Exercise 3.54: Define a procedure
|
|
mul-streams, analogous to add-streams, that produces the
|
|
elementwise product of its two input streams. Use this together with the
|
|
stream of integers to complete the following definition of the stream
|
|
whose
|
|
|
|
n
|
|
|
|
th
|
|
|
|
|
|
element (counting from 0) is
|
|
|
|
n
|
|
+
|
|
1
|
|
|
|
factorial:
|
|
|
|
|
|
(define factorials
|
|
(cons-stream 1 (mul-streams ⟨??⟩ ⟨??⟩)))
|
|
|