// Miya Natsuhara // 08-17-2019 // CSE142 // TA: Grace Hopper // Prints out some information about the Employee, Server, Chef, and HeadChef classes to // demonstrate the mechanics of inheritance and polymorphism. import java.util.*; public class EmployeeClient { public static void main(String[] args) { Employee ethel = new Employee(); System.out.println("Employee:"); printInfo(ethel); System.out.println(); Server rebecca = new Server(); int x = 3; double y = 3; String s = "hello"; System.out.println("Server:"); printInfo(rebecca); System.out.println(" Earned tips: " + rebecca.collectTips(5.00)); System.out.println(); Chef michael = new Chef(); System.out.println("Chef:"); printInfo(michael); System.out.println(); HeadChef gordonRamsay = new HeadChef(); System.out.println("Head Chef:"); printInfo(gordonRamsay); System.out.println(" This week's specials: " + Arrays.toString(gordonRamsay.setSpecials())); System.out.println(); } // Prints out hours, pay, and vacation days information about the given Employee // Employee worker: the Employee whose information is printed public static void printInfo(Employee worker) { System.out.println(" Works " + worker.getHours() + " per week"); System.out.printf(" Earns $%.2f per hour\n", worker.getHourlyRate()); System.out.println(" Gets " + worker.getVacationDays() + " vacation days per year"); } }