Question: develop code a rectangle class instance variables for the length and width of the sides will be of type in need two instance variables, which
develop code a rectangle class
instance variables for the length and width of the sides will be of type in
need two instance variables, which should be private
a constructor is needed ( to initialize the instance variables), constructor will take width and length as its parameters
two accessor methods- getLength() and getWidth()
two computation methods-calcArea() and calcPerimeter()
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
