funciton isValInTree now returns a boolean to show if a value is in a tree