Hybrid Inheritance:

When two child access same properties of parent class

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 college{
    void fees(){
	System.out.println("Pay before time");
	}
}

          

Test.java

class test{
	public static void  main(String args[]){
	 canteen c=new canteen();
	 c.food();
	 student s=new student();
	 s.bus();
	 s.fees();
	
	}
} 
       

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 student  class
          

Address

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