Radius of a circle having area equal to the sum of area of the circles having given radii | Function to calculate radius of the circle having area equal to sum of the area of two circles with given radii ; Area of first circle ; Area of second circle ; Area of third circle ; Radius of third circle ; Driver code ; Given radius ; Prints the radius of the required circle
def findRadius ( r1 , r2 ) : NEW_LINE INDENT a1 , a2 , a3 , r3 = 0 , 0 , 0 , 0 ; NEW_LINE a1 = 3.14 * r1 * r1 ; NEW_LINE a2 = 3.14 * r2 * r2 ; NEW_LINE a3 = a1 + a2 ; NEW_LINE r3 = ( ( a3 / 3.14 ) ** ( 1 / 2 ) ) ; NEW_LINE return r3 ; NEW_LINE DEDENT if __name__ == ' _ _ main _ _ ' : NEW_LINE INDENT r1 = 8 ; r2 = 6 ; NEW_LINE print ( int ( findRadius ( r1 , r2 ) ) ) ; NEW_LINE DEDENT