Sup — Java Com Work

package com.example.work.employee;

public class Employee { protected String name; protected int id; protected double baseSalary;

import com.example.work.employee.Employee; import com.example.work.employee.Manager; import com.example.work.util.Formatter; sup java com work

package com.example.work.util;

import com.example.work.employee.Employee; package com

@Override public double getSalary() { // use super.getSalary() to reference parent behavior return super.getSalary() + bonus; }

@Override public String getDetails() { return String.format("Manager[id=%d,name=%s,salary=%.2f,bonus=%.2f]", id, name, getSalary(), bonus); } } File: com/example/work/util/Formatter.java protected int id

public double getSalary() { return baseSalary; }