Amazon Interview Question

oop question, design class for a tree which could represent the expression