-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
Description
Error
Traceback (most recent call last):
File "\\wsl$\Ubuntu\home\kwojtas\cormenpy\test\test_chapter11\test_textbook11_5.py", line 16, in test_perfect_hashing
table, h = perfect_hashing_init(keys)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "\\wsl$\Ubuntu\home\kwojtas\cormenpy\src\chapter11\textbook11_5.py", line 12, in perfect_hashing_init
p = random.choice(list(sieve.primerange(max_key + 1, 2 * max_key + 1)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\kwojtas\AppData\Local\Programs\Python\Python311\Lib\random.py", line 370, in choice
raise IndexError('Cannot choose from an empty sequence')
IndexError: Cannot choose from an empty sequence