Skip to content

Commit 569114e

Browse files
authored
Update find-the-shortest-superstring.py
1 parent b4ac97f commit 569114e

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

Python/find-the-shortest-superstring.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ def shortestSuperstring(self, A):
1111
overlaps = [[0]*n for _ in xrange(n)]
1212
for i, x in enumerate(A):
1313
for j, y in enumerate(A):
14-
if i == j:
15-
continue
1614
for l in reversed(xrange(min(len(x), len(y)))):
1715
if y[:l].startswith(x[len(x)-l:]):
1816
overlaps[i][j] = l

0 commit comments

Comments
 (0)