0% found this document useful (0 votes)
23 views

Java Lab Evaluation

The document defines two interfaces abc and xyz where xyz extends abc. It also defines a class jkl that implements xyz and overrides the methods defined in both interfaces. The main method creates an object of jkl and calls the overridden methods to print the salary calculations.

Uploaded by

Tabrej
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
23 views

Java Lab Evaluation

The document defines two interfaces abc and xyz where xyz extends abc. It also defines a class jkl that implements xyz and overrides the methods defined in both interfaces. The main method creates an object of jkl and calls the overridden methods to print the salary calculations.

Uploaded by

Tabrej
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

1)

Evaluation 3

Rajesh 11714376

interface abc

String name="rajesh";

int aki(int x,int y);

interface xyz extends abc

String name2="tabrej";

int aki1(int x,int y);

class jkl implements xyz

public int aki(int x,int y)

int tot=(x+y)*6;

int tax=((10/100)*tot);

int allowences=((13/100)*tot);

int fin=tot-(tax+allowences);

return(fin);

public int aki1(int x,int y)

{
int tot=(x+y)*6;

int tax=((10/100)*tot);

int allowences=((13/100)*tot);

int fin=tot-(tax+allowences);

return(fin);

class dang

public static void main(String[] args)

xyz d;

d=new jkl();

System.out.println("salary of employee :"+d.name +" "+d.aki(10000,12000));

System.out.println("salary of employee :"+d.name2 +" "+d.aki1(14000,16000));

You might also like