Question: Given the following Java code. What is the output? * } public class worker public Worker (String name, double rate) public double calcComm (double sales)
Given the following Java code. What is the output? * } public class worker public Worker (String name, double rate) public double calcComm (double sales) { double commission = rate * sales; return commission; 3 public static void main (String args[]) { Worker w = new Worker ("Rawley Friday", 0.2); System.out.println("Commission: " + w.calcomm (700.00)); 3 Commission: 1.4 Commission: 140.0 Commission: 14.0 O Commission: 700.0
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
