17 lines
564 B
Java
17 lines
564 B
Java
|
package VL06.Aufgabe01;
|
||
|
|
||
|
public class LeitenderAngestellter extends Angestellter {
|
||
|
protected double bonus;
|
||
|
|
||
|
LeitenderAngestellter(int personalNummer, String name, String vorname, double monatsGehalt, double bonus) {
|
||
|
super(personalNummer, name, vorname, monatsGehalt);
|
||
|
this.bonus = bonus;
|
||
|
}
|
||
|
|
||
|
void print() {
|
||
|
System.out.printf("\n%s, %s (%d):\n", this.getName(), this.getVorname(), this.getPersonalNummer());
|
||
|
System.out.printf(" Monatsgehalt: %.2f Euro\n", this.monatsGehalt);
|
||
|
System.out.printf(" Bonus: %.2f Euro\n", this.bonus);
|
||
|
}
|
||
|
}
|