Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (define (P x y)
- (cond ((= x 1) 1)
- ((= y x) 1)
- ((+ (P x (- y 1))
- (P (- x 1) (- y 1))))))
- (define (Row-sum-P y)
- (define (P-iter x y)
- (if (< x (+ y 1))
- (+ (P x y)
- (P-iter (+ 1 x) y))))
- (P-iter 1 y))
- (Row-sum-P 5)
Add Comment
Please, Sign In to add comment