Determine if two triangles overlap: Difference between revisions
Content deleted Content added
Alextretyak (talk | contribs) Added 11l |
|||
Line 2,453:
=={{header|Mathematica}}/{{header|Wolfram Language}}==
<lang Mathematica>p1 = Polygon@{{0, 0}, {5, 0}, {0, 5}};
p2 = Polygon@{{0, 0}, {5, 0}, {0, 6}};
! RegionDisjoint[p1, p2]
Line 2,481 ⟶ 2,480:
p1 = Polygon@{{0, 0}, {1, 0}, {0, 1}};
p2 = Polygon@{{1, 0}, {2, 0}, {1, 1}};
! RegionDisjoint[p1, p2]</lang>
{{out}}
<pre>True
True
False
Line 2,491 ⟶ 2,488:
False
False
True</pre>
=={{header|Modula-2}}==
|