Skip to content
Snippets Groups Projects
Commit 33d836ef authored by Mathieu Valois's avatar Mathieu Valois
Browse files

Fix issue where closest word was not correctly chosen

parent fd22427b
No related branches found
No related tags found
No related merge requests found
......@@ -53,7 +53,7 @@ class Robustness:
if dist < lowest_distance:
lowest_distance = dist
lowest_index = j
self.swap(i, j)
self.swap(i, lowest_index)
after = time.time()
print("Found the %dth closest word in %d seconds" % (i, after-before))
yield self.l[i]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment