Spaces:
Sleeping
Sleeping
kmaurinjones
commited on
Commit
•
329aee5
1
Parent(s):
9bfeaff
Update wordle_functions.py
Browse files- wordle_functions.py +12 -5
wordle_functions.py
CHANGED
@@ -629,11 +629,18 @@ def wordle_wizard(word_list: list, max_guesses: int = None,
|
|
629 |
|
630 |
if return_stats == False:
|
631 |
if verbose == True:
|
632 |
-
|
633 |
-
|
634 |
-
|
635 |
-
|
636 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
637 |
|
638 |
reduction_per_guess.append(len(potential_next_guesses))
|
639 |
|
|
|
629 |
|
630 |
if return_stats == False:
|
631 |
if verbose == True:
|
632 |
+
if len(potential_next_guesses) > 1:
|
633 |
+
print(f"At this point:")
|
634 |
+
print(f"\t{len(word_list) - len(potential_next_guesses)}, {round((len(word_list) - len(potential_next_guesses)) / len(word_list) * 100, 2)}% of total words have been eliminated, and")
|
635 |
+
print(f"\t{len(potential_next_guesses)}, {round(len(potential_next_guesses) / len(word_list) * 100, 2)}% of total words remain possible.\n")
|
636 |
+
# record_list.append(f"At this point:")
|
637 |
+
record_list.append(f"{len(word_list) - len(potential_next_guesses)} ({round((len(word_list) - len(potential_next_guesses)) / len(word_list) * 100, 2)}% of all) words have been eliminated, and {len(potential_next_guesses)} ({round(len(potential_next_guesses) / len(word_list) * 100, 2)}% of all) words are still possible.\n")
|
638 |
+
else:
|
639 |
+
print(f"At this point:")
|
640 |
+
print(f"\t{len(word_list) - len(potential_next_guesses)}, {round((len(word_list) - len(potential_next_guesses)) / len(word_list) * 100, 2)}% of total words have been eliminated, and")
|
641 |
+
print(f"\t{len(potential_next_guesses)}, {round(len(potential_next_guesses) / len(word_list) * 100, 2)}% of total words remain possible.\n")
|
642 |
+
# record_list.append(f"At this point:")
|
643 |
+
record_list.append(f"{len(word_list) - len(potential_next_guesses)} ({round((len(word_list) - len(potential_next_guesses)) / len(word_list) * 100, 2)}% of all) words have been eliminated, and only {len(potential_next_guesses)} ({round(len(potential_next_guesses) / len(word_list) * 100, 2)}% of all) word is still possible.\n")
|
644 |
|
645 |
reduction_per_guess.append(len(potential_next_guesses))
|
646 |
|