Respuesta :
Answer:
public static double areaSum(Circle c1, Circle c2){
double c1Radius = c1.getRadius();
double c2Radius = c2.getRadius();
return Math.PI * (Math.pow(c1Radius, 2) + Math.pow(c2Radius, 2));
public static void main(String[] args){
Circle c1 = new Circle(6.0);
Circle c2 = new Circle(8.0);
areaSum(c1,c2);
}
Explanation:
The function calculates the sum of the area of two circles with their radius given. The program written in python 3 goes thus :
import math
#import the math module
def areaSum(c1, c2):
#initialize the areaSum function which takes in two parameters
c1 = math.pi * (c1**2)
# calculate the area of the first circle
c2 = math.pi * (c2**2)
#Calculate the area of the second circle
return c1+c2
#return the sum of the areas
print(areaSum(6.0, 8.0))
A sample run of the program is attached
Learn more : https://brainly.com/question/19973164
