What is the problem with this code?

class Tree
{

boolean isBalanced(Node root)
{
    int lht = heightleft(root.left);
    int rht = heightright(root.right);
    int ht=Math.abs(lht-rht);
    if(ht>1)
        return false;
    else
        return true;
}

int heightleft(Node root)
{
    if(root==null)
        return 0;
    return(Math.max(heightleft(root.left),heightleft(root.right)))+1;
}
int heightright(Node root)
{
    if(root==null)
        return 0;
    int rr1=heightright(root.right);
    int rr2=heightright(root.left);
    return (Math.max(rr1,rr2))+1;
}

}

hey @sarveshbibhuty
before this line
int lht = heightleft(root.left);
int rht = heightright(root.right);
int ht=Math.abs(lht-rht);
if(ht>1)
return false;
else
return true;
call isBalanced(root.left) and isBalanced(root.right)

class Tree
{

boolean isBalanced(Node root)
{
if(root==null){
return true;
}
boolean lb = isBalanced(root.left);
 boolean rb = isBalanced(root.right)
    int lht = heightleft(root.left);
    int rht = heightright(root.right);
    int ht=Math.abs(lht-rht);
    if(lb && rb && ht<=1)
        return true
    else
        return false 
}

int heightleft(Node root)
{
    if(root==null)
        return 0;
    return(Math.max(heightleft(root.left),heightleft(root.right)))+1;
}
int heightright(Node root)
{
    if(root==null)
        return 0;
    int rr1=heightright(root.right);
    int rr2=heightright(root.left);
    return (Math.max(rr1,rr2))+1;
}

}

boolean lb = isBalanced(root.left); boolean rb = isBalanced(root.right) Why do we need to add these lines ?

tree is Balanced
Satisfy these conditions
1)Left subtree of T is balanced
2) Right subtree of T is balanced
3) The difference between heights of left subtree and right subtree is not more than 1.
if any one of the condition is fail
tree is not Balanced