From 983f172d6ec96edada471c52012d8af3e0f80279 Mon Sep 17 00:00:00 2001 From: Christian Clauss Date: Wed, 14 Apr 2021 21:18:49 +0200 Subject: [PATCH] Simplify password_generator() --- other/password_generator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/other/password_generator.py b/other/password_generator.py index 35e11e4dfb78..cf7250c814ff 100644 --- a/other/password_generator.py +++ b/other/password_generator.py @@ -16,7 +16,7 @@ def password_generator(length=8): >>> len(password_generator(-1)) 0 """ - chars = tuple(ascii_letters) + tuple(digits) + tuple(punctuation) + chars = ascii_letters + digits + punctuation return "".join(choice(chars) for x in range(length))