Skip to content

Instantly share code, notes, and snippets.

View Parithi's full-sized avatar
👨‍💻
Codin!

ElamParithi Arul Parithi

👨‍💻
Codin!
View GitHub Profile
START
SET numExhibits = Total number of exhibits
FOR each exhibit e = 1 to numExhibits
Find midpoint m
Find adjacent exhibits of e by doing this
FOR every other exhibit a = 1 to numExhibits do the following
IF e is sharing coordinate(s) with a, add a.
ELSE Line l drawn between e.m and a.m intersects any side s of exhibit
FOR each exhibit x = 1 to numExhibits do the following
Use LeMothe’s algorithm to find intersection point of two line segments l and s.