3 Inheritance Program
3 Inheritance Program
public void Emp_Info(String Emp_name, String Emp_adress, String Emp_mail, int Emp_ID, long
Emp_Mb_no){
this.Emp_name=Emp_name;
this.Emp_adress=Emp_adress;
this.Emp_mail=Emp_mail;
this.Emp_ID=Emp_ID;
this.Emp_Mb_no=Emp_Mb_no;
return this.BP;
}
public void setBP(double BP){
this.BP=BP;
System.out.println("Programmer Information:-");
return this.BP;
this.BP=BP;
return this.BP;
this.BP=BP;
return this.BP;
this.BP=BP;
obj1.Emp_Info("Ram","Shrirampur","[email protected]",6,9284543702l);
obj1.display();
obj2.setBP(9000.20);
obj2.getBP();
obj2.Gross_salary();
obj2.Net_salary();
Employee obj3 = new Team_Lead();
obj3.Emp_Info("Sham","Nagar","[email protected]",7,9112772159l);
obj3.display();
obj4.setBP(2000.12);
obj4.getBP();
obj4.Gross_salary();
obj4.Net_salary();
obj5.Emp_Info("Sundar","Sangmner","[email protected]",34,9876678959l);
obj5.display();
obj6.setBP(1200.12);
obj6.getBP();
obj6.Gross_salary();
obj6.Net_salary();
obj7.Emp_Info("Ravi","Pune","[email protected]",84,7007657892l);
obj7.display();
obj8.setBP(6765.12);
obj8.getBP();
obj8.Gross_salary();
obj8.Net_salary();