from __future__ import annotations (#2464)
* from __future__ import annotations
* fixup! from __future__ import annotations
* fixup! from __future__ import annotations
* fixup! Format Python code with psf/black push
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
This commit is contained in:
@@ -7,12 +7,13 @@ Source: on page 3 of https://crypto.stanford.edu/~dabo/papers/RSA-survey.pdf
|
||||
More readable source: https://www.di-mgt.com.au/rsa_factorize_n.html
|
||||
large number can take minutes to factor, therefore are not included in doctest.
|
||||
"""
|
||||
from __future__ import annotations
|
||||
|
||||
import math
|
||||
import random
|
||||
from typing import List
|
||||
|
||||
|
||||
def rsafactor(d: int, e: int, N: int) -> List[int]:
|
||||
def rsafactor(d: int, e: int, N: int) -> list[int]:
|
||||
"""
|
||||
This function returns the factors of N, where p*q=N
|
||||
Return: [p, q]
|
||||
|
||||
Reference in New Issue
Block a user