Question: Java Language Moving to another question will save this response Question 17 int x; intyi Explain why the following Rectangle class is giving the error
Moving to another question will save this response Question 17 int x; intyi Explain why the following Rectangle class is giving the error at line 11P And What the programmer has to do to resolve the error 1 public class Triangle { Os 2 private int base; private int height; 4 5 68 public Triangle(int basel, int heightl) { 7 base = basel; 8 height = height; } 10 public static double area( { 11 return 0.5 * base height 12 ) 13 } 9 Th
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
