Write a Java program to test whether two lines PQ and RS are parallel. The four points are P(x1, y1), Q(x2, y2), R(x3, y3), S(x4, y4)
Input:
−100 ≤ x1, y1, x2, y2, x3, y3, x4, y4 ≤ 100
Each value is a real number with at most 5 digits after the decimal point.
Expected Output:
Input P(x1,y1),separated by a space.
5 6
Input Q(x2,y2),separated by a space.
4 2
Input R(x3,y3),separated by a space.
5 3
Input S(x4,y4),separated by a space.
5 6
Two lines are not parallel.
Sample Output:
need an explanation for this answer? contact us directly to get an explanation for this answer