Implemented basic leaf tree