js: binary tree objects