Description:
Multilevel inheritance refers to a mechanism in OO technology where one can inherit from a derived class, thereby making this derived class the base class for the new class.
Learn through my videos:

Program:
package inheritance;
public class Inheritance {
    public static void main(String[] args)
    {
        AddSubMul obj=new AddSubMul();
        obj.num1=5;
        obj.num2=4;
        obj.sum();
        System.out.println(obj.result);
        obj.sub();
        System.out.println(obj.result);
         obj.multi();
        System.out.println(obj.result);       
          }  
}
class Add
{
    int num1,num2,result;
    public void sum()
    {
        result=num1+num2;
    }
}
class AddSub extends Add
{    
    public void sub()
    {
        result=num1-num2;
    }
}
class AddSubMul extends AddSub
{    
    public void multi()
    {
        result=num1*num2;
    }
}
Output:
9
1
20
Logic:
In Multilevel inheritance the more than one subclasses inherit the properties of the parent class.