Professional Documents
Culture Documents
1313003
(Page No.
Date
rockcalo 4
ha cancapt
Alm alrile a proqtom do danonstrale
pause cday and dlanved cain jaea
Theory
The he maun
base lass is class
Boge elass
h e r e clazmved classeainant th featoe I is alda knoLwn
cu tho 3upeidasg o otd cdass.
Code i
class employe
mp-o empn0
name nam
salarySa
Teacher's Signature
public void emplo data ()
publie void
Public monager dasa )
Sysn ou pridln ("\n Employ no "
temp-n o)
Sys lem oud pntln (Name + name ,
Sys lem oud pmntn Sealany Asalamy )
Syslen0ut println C t Rewa d + TeLoUrd)
3. enpioye
protected nt emp_no,
proterted tet
ystem.out.printinnEmployno,enp_no);
wstem.out.printIn"Salarya"+salary):
19 class manager extends eploye
nt reard:
22 manager (int enpno, String nam, int sal, int p)
ubic
uper (em
, Sal)
renard-p;
ublic vo1d managerdata()
System.out.printin O
trntn arsry
Execute
eu
and executed in 0.83 secis)
Salary=20000
no.-2
00
Reward-1000
Note