summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Doc/library/concurrent.futures.rst4
1 files changed, 4 insertions, 0 deletions
diff --git a/Doc/library/concurrent.futures.rst b/Doc/library/concurrent.futures.rst
index 47ca6b38f8..3890e49f59 100644
--- a/Doc/library/concurrent.futures.rst
+++ b/Doc/library/concurrent.futures.rst
@@ -257,6 +257,10 @@ ProcessPoolExecutor Example
1099726899285419]
def is_prime(n):
+ if n < 2:
+ return False
+ if n == 2:
+ return True
if n % 2 == 0:
return False