Given the coordinates xy of a center of a circle and its radius write a program which will determine whether a point lies inside the circleon the circle or outside the circle conditional statements?

1 answer

Answer

1166454

2026-07-20 07:55

+ Follow

Center is at (Xc, Yc ). Radius = R.

=======================================

Print "Input the coordinates of point 'P', separated by a comma."

Input A, B

D = (Xc - A)2 + (Yc - B)2

If D < R2 then print "'P' is inside the circle."

If D = R2 then print "'P' is on the circle."

If D > R2 then print "'P' is outside the circle."

by arup nandy

ReportLike(0ShareFavorite

Copyright © 2026 eLLeNow.com All Rights Reserved.