Wayfair Interview Question

Code a Binary tree algorithm, review a code snippet for OOD principles