Multilevel inheritance:

when child class access properties of parent class and super class parent

Example

College.java

//Parent class
class college{ 
   void bus(){
    System.out.println("It is compulsory");
   }
}
          

canteen.java

//parent class --college
//child class--canteen
class canteen extends college{
  void food(){ 
   System.out.println("Nice food");  
  }
}
          

student.java

class student extends canteen{
    void fees(){
	System.out.println("Pay before time");
	}

	public static void  main(String args[]){
	  student s=new student();
	  s.bus();         //declare in college class
	  s.food();        //declare food() method in canteen class
	  s.fees();        //Declare fees() method in student class
	
	}
}   
       

output:	
IT is compulsory     //this is output come from  top parent class
Nice food            //this is coming from immidiate parent class
Pay before fees      //this is output come from child class
          

Address

Plot number-56/1
Near Gurudwara
LandMark :
Opposite A.N.D college
Govindpuri Metro station
New Delhi
Mobile number:
8826034620