求一java编程的程序

来源:百度知道 编辑:UC知道 时间:2024/07/07 16:15:01
Write a program that draws a circle with radius 100 and center (200, 200). Ask the user to specify the x- and y-coordinates of a
point. Draw the point as a small circle. If the point lies inside the circle, color the small circle green. Otherwise, color it red. In your exercise, define a class Circle and a method boolean
isInside(Point2D.Double p).

翻译过来就是以(200,200)为圆心画一个半径为100的圆,另画一个点(以小圆的形式),如果此点在圆内,显示为绿色;在圆外,显示为红色。
定义一个class Circle和一个method boolean
isInside(Point2D.Double p)

明天我帮你写,你把这个问题发到我的留言里

应该是用Swing和AWT来做的,不过本人很久都没用到这些东西了,所以帮不了忙了。 建议你可以去看一下API,这些方法里面肯定会有的...