Binary search tree

Nice bit of metaprogramming here.