-
编写一个线段类 MyLine,要求如下:
主要属性有: x ,y ;类型为Point (查看API)
编写构造方法,如 MyLine(Point p1...
编写一个线段类 MyLine,要求如下:
主要属性有: x ,y ;类型为Point (查看API)
编写构造方法,如 MyLine(Point p1 , Point p2)
编写5个成员方法。如:
检查线段是否位于第一象限check()…
求线段的长度 length() …
判断两条直线是否相交(另一线段作为参数)。
编写一点到该线段(或延长线)的距离
其他方法。
注:编写方法时,考虑利用Point类的方法
编写测试程序-Write a segment class MyLine, requirements are as follows: The main attributes are: x, y type Point (see API) the preparation of construction methods, such as MyLine (Point p1, Point p2) prepared by five members of the method. Such as: Check whether the line segment in the first quadrant check () ... order to segment the length of the length () ... to determine whether the two straight lines intersect (the other segment as a parameter). The preparation of 1:00 to the line segment (or extension) of the distance from other methods. Note: The preparation method, consider using the Point class approach to preparing test program
- 2022-05-10 16:17:22下载
- 积分:1
-
java程序,适合初学者,可编译运行,已测试
java程序,适合初学者,可编译运行,已测试-java procedures for beginners, the compiler can run, have tested
- 2022-04-08 09:10:53下载
- 积分:1
-
Java2Demo版,不错的东东,需要先安装j2sdk
Java2Demo版,不错的东东,需要先安装j2sdk-Java2Demo edition of the Eastern Yes, the need for installing j2sdk
- 2022-01-26 05:19:26下载
- 积分:1
-
Neuronals nets with Java.
Neuronals nets with Java.
- 2022-03-13 10:53:37下载
- 积分:1
-
有关天气的,20分钟内完成
有关天气的,20分钟内完成-on the weather, completed within 20 minutes
- 2022-06-03 02:34:28下载
- 积分:1
-
一个简单的使用电话卡的JAVA程序
一个简单的使用电话卡的JAVA程序-use of a simple phone card procedures JAVA
- 2022-03-26 17:54:54下载
- 积分:1
-
open meeting Programming Image
次编程实现打开图象-open meeting Programming Image
- 2022-10-31 22:50:03下载
- 积分:1
-
Java code to do the Sokoban game, I hope that pointing error
Java代码做的推箱子小游戏,希望各位指点错误-Java code to do the Sokoban game, I hope that pointing error
- 2022-05-17 13:10:24下载
- 积分:1
-
JSP动态网站开发与应用,提供的是源代码,按章节分类的。
JSP动态网站开发与应用,提供的是源代码,按章节分类的。-JSP dynamic web site development and application
- 2022-07-02 04:05:34下载
- 积分:1
-
NMS jdbm
NMS jdbm
- 2022-03-24 13:45:20下载
- 积分:1