Whatfix Interview Question

write a program to assign inputs to a binary tree