Higher |D'rcler rIlrees
Recall our denition of binary trees:
datatype 3a tree = Empty
I Node of 3a tree a: 'a 1: a tree
"e 1i'rill he 1.rorlring with some higher-order functions on these trees.
Task 1 Dene a recursive it'll. Function
Seq.map : ('a -> 'b) -> 'a Seq.seq -> 'b Seq.seq, which takes a function and
a sequence and returns a sequence whose elements are the result of applying the
given function to the corresponding element in the given sequence.
Seq.reduce : ('a * 'a