Easy and short c++ code


#1
    if(A==NULL && B==NULL){
        return true;
    }
    else if(A==NULL||B==NULL){
        return false;
    }
    else if(A->val!=B->val){
        return false;
    }
    else{
        return isSameTree(A->left,B->left) && isSameTree(A->right, B->right);
    }
}```