we are returning 1 if(root==target) and then we are checking if(L!=1) means we have found the target node in left sub tree , i think it should be if(L==1) instead if if(L!=1)
we are returning 1 if(root==target) and then we are checking if(L!=1) means we have found the target node in left sub tree , i think it should be if(L==1) instead if if(L!=1)