Added Tree class sample, with tests from the book