Write a class with 3 overdloaded functions by the name PERIMETER to find the perimeter of square ,a rectangle and a circle using the following formulas for square 4*S for rectangle 2*(l+b) for circle 2* pie*r ( WRITE A Variable Description TABLE ) (main is NOT required )
.
.
please answer to this question fast :'(((((
Answers
Answered by
1
Answer:
class test1
{
double PERIMETER(double a)
{
double p = 4*a;
return p;
}
{
double PERIMETER (double a, double b)
{
double a = 2*(a+b);
return a;
}
{
double PERIMETER (double r)
{
double a = 2*math.pi()*r;
return a;
}
}
hope it helps
i know almost alll the programs for java ,paython and etchical hacking.
please follow mmee
please mark as branliest.
Similar questions
Math,
3 months ago
English,
3 months ago
Math,
3 months ago
Math,
7 months ago
Social Sciences,
7 months ago
Political Science,
11 months ago
Physics,
11 months ago