a simple implementation of a balanced red black tree