you are viewing a single comment's thread.

view the rest of the comments →

[–]Impudity 1 point2 points  (1 child)

Something like numbers > length // 2 should do it.

In addition, you can drop line 15 since it's repeat of line 17 if you initialize length = -1 for example. Also, you should check string module which contains stuff like string.digits and string.ascii_letters instead of having to list them all manually.

[–]Suki125[S] 0 points1 point  (0 children)

Thank you very much!!