Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
| Download
Path: Assignment 04/A04.ipynb
Views: 99Image: ubuntu2204
Kernel: SageMath 10.0
In [1]:
---------------------------------------------------------------------------
NameError Traceback (most recent call last)
Cell In [1], line 87
84 unrecoverbe_encoded_message = b'il0v3you\xa8#'
86 assert baby_rs_encode(message) == expected_encoded_message
---> 87 assert baby_rs_decode(expected_encoded_message) == message
88 assert baby_rs_decode(recoverable_encoded_message_1) == message
89 assert baby_rs_decode(recoverable_encoded_message_2) == message
Cell In [1], line 62, in baby_rs_decode(encoded_message)
58 encoded_elements = [F.from_integer(b) for b in encoded_message]
60 polynomial_votes = {}
---> 62 for indices in itertools.combinations(range(n), k):
63 points = [(alpha**i, encoded_elements[i]) for i in indices]
64 g = R.lagrange_polynomial(points)
NameError: name 'itertools' is not defined
In [0]:
In [0]:
In [0]: