Ordered triples

Write a procedure to find all ordered triples of distinct positive integers i, j, and k less than or equal to a given integer n that sum to a given integer s.

There are no comments yet.

Authentication required

You must log in to post a comment.

(check-equal? (make-triple-sum 4 6) '((3 2 1)))
(check-equal? (make-triple-sum 3 6) '((3 2 1)))
(check-equal? (length (make-triple-sum 9 9)) 3)