Google Interview Question

Problems dealing with tree data structure