MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / is_prime_low_num

Function is_prime_low_num

ciphers/rabin_miller.py:28–210  ·  view source on GitHub ↗
(num: int)

Source from the content-addressed store, hash-verified

26
27
28def is_prime_low_num(num: int) -> bool:
29 if num < 2:
30 return False
31
32 low_primes = [
33 2,
34 3,
35 5,
36 7,
37 11,
38 13,
39 17,
40 19,
41 23,
42 29,
43 31,
44 37,
45 41,
46 43,
47 47,
48 53,
49 59,
50 61,
51 67,
52 71,
53 73,
54 79,
55 83,
56 89,
57 97,
58 101,
59 103,
60 107,
61 109,
62 113,
63 127,
64 131,
65 137,
66 139,
67 149,
68 151,
69 157,
70 163,
71 167,
72 173,
73 179,
74 181,
75 191,
76 193,
77 197,
78 199,
79 211,
80 223,
81 227,
82 229,
83 233,
84 239,
85 241,

Callers 2

generate_large_primeFunction · 0.85
rabin_miller.pyFile · 0.85

Calls 1

rabin_millerFunction · 0.85

Tested by

no test coverage detected