From bde9529bb3ff94397ae103fa6ff993c31931a400 Mon Sep 17 00:00:00 2001 From: Ramakrishnan Muthukrishnan <vu3rdd@gmail.com> Date: Sun, 10 Jul 2011 10:11:44 +0530 Subject: [PATCH] solution to 3.60. Untested. Skipping 3.61 and 3.62. --- src/sicp/ex3_60.rkt | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/sicp/ex3_60.rkt diff --git a/src/sicp/ex3_60.rkt b/src/sicp/ex3_60.rkt new file mode 100644 index 0000000..1110c28 --- /dev/null +++ b/src/sicp/ex3_60.rkt @@ -0,0 +1,10 @@ +#lang racket + +(define (mul-series s1 s2) + (cons-stream (* (stream-car s1) + (stream-car s2)) + (add-streams (scale-stream (stream-cdr s1) (stream-car s2)) + (add-streams + (scale-stream (stream-cdr s2) (stream-car s1)) + (mul-series (stream-cdr s1) + (stream-cdr s2)))))) \ No newline at end of file -- 2.45.2