Union-set for sets represented as unordered lists

Implement the union-set operation for the unordered-list representation of sets.


There are no comments yet.

Authentication required

You must log in to post a comment.

Login
(define first '(1 2 3 5))
(define second '(3 4 5 6))

(check-equal? (union-set first second) '(6 4 1 2 3 5))
(check-equal? (union-set first '()) first)
(check-equal? (union-set '() second) second)