How to find the coordinates of the point of intersection of two segments behind the coordinates of their beginnings and ends? (C / C ++). For example, the user enters:
- ax1, ay1, ax2, ay2 - coordinates of the beginning and end of the first straight line;
- bx1, by1, bx2, by2 - coordinates of the beginning and end of the second straight line;
- cx, cy - coordinates of a certain point from which we will compare the intersection found;
That is, the coordinates of two segments and points are entered, you need to know - is the point the intersection of these segments?