8000 Added comments. · pythonpeixun/practice-python@45a39f6 · GitHub
[go: up one dir, main page]

Skip to content

Commit 45a39f6

Browse files
committed
Added comments.
1 parent e9b25b3 commit 45a39f6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

convex-hull/convex-hull.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ def compute_hull(self):
5151
far_point = None
5252
while far_point is not start:
5353

54+
# get the first point (initial max) to use to compare with others
5455
p1 = None
5556
for p in points:
5657
if p is point:
@@ -62,6 +63,7 @@ def compute_hull(self):
6263
far_point = p1
6364

6465
for p2 in points:
66+
# ensure we aren't comparing to self or pivot point
6567
if p2 is point or p2 is p1:
6668
continue
6769
else:

0 commit comments

Comments
 (0)
0