-
编写一个线段类 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的编程指导,适应初学者和有一定基础的编程爱好者,有助于对Java的学习。-Java programming guide, to adapt to a certain basis for beginners and enthusiasts programming, contribute to learning Java.
- 2022-07-18 11:59:47下载
- 积分:1
-
java基础编程示例1
java基础编程示例1-an example
- 2022-08-24 09:54:47下载
- 积分:1
-
操作EXCEL文件
本实例演示使用jxl包实现对excel文件的操作
操作EXCEL文件
本实例演示使用jxl包实现对excel文件的操作-EXCEL file operation using the example demo package jxl achieve operational excel document
- 2023-04-10 02:20:03下载
- 积分:1
-
Java写的数据链接协议模拟器,学java的人可以学习学习
Java写的数据链接协议模拟器,学java的人可以学习学习-Java to write the data link protocol simulator, learning java people can learn to learn
- 2022-03-01 03:10:07下载
- 积分:1
-
企业门户网站, 企业门户网站,企业门户网站。
企业门户网站, 企业门户网站,企业门户网站。-企业门户网站,企业门户网站,企业门户网站,企业门户网站.
- 2023-02-19 21:20:03下载
- 积分:1
-
移动平台例程反向顺序
移动misc平台反向订购例程-mobile platform routines reverse order
- 2022-04-13 00:08:06下载
- 积分:1
-
Java各种排序算法代码,转载自-JAVA爱好者:http://www.javafan.net...
Java各种排序算法代码,转载自-JAVA爱好者:http://www.javafan.net-Java various sorting algorithm code, reprinted from-JAVA lovers : http :// www.javafan.net
- 2022-08-16 22:12:34下载
- 积分:1
-
use graphical interface to achieve Timer can be set
用图形界面实现Timer,可以设置时间段,可以关闭和启动Timer用任意键完成。-use graphical interface to achieve Timer can be set-up time of the closing and can be activated with Timer arbitrary keys completed.
- 2022-05-20 03:07:22下载
- 积分:1
-
P2P协议GUNTELLA的java源代码
P2P协议GUNTELLA的java源代码-P2P protocol GUNTELLA the java source code
- 2022-01-25 17:50:45下载
- 积分:1