Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

....................A total of 5 class files will be created . Shape - numberofsides: int=0 + getPerimeter(): double + getArea(): double + print) Y A Circle

image text in transcribed

....................A total of 5 class files will be created

.

Shape - numberofsides: int=0 + getPerimeter(): double + getArea(): double + print) Y A Circle Square - sideLength: double radius: double Rectangle -shortsidelength: double - longsidelength: double Fitsinsquare(Square): boolean getPermeter(): double getArea(): double fitsinrectangle(Rectangle): boolean getPerimetero: double + getArea(): double + getPerimeter(): double + getArea(): double encode the classes, the diagram of which is given above, in C#. Write the members of the classes (properties and methods) in a way that is appropriate and functional to their meaning. -Control access to class properties using C# property. Each class is in a different file (.cs extension) must be present. -the print() method must print the values of all properties of the corresponding class and the values returned by methods that do not take parameters to the screen (console). - Create an instance of each different class by typing a driver/test class and call the print() methods in a multiform (polymorphic) format

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Spatial Databases A Tour

Authors: Shashi Shekhar, Sanjay Chawla

1st Edition

0130174807, 978-0130174802

Students also viewed these Databases questions