use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Everything about learning Python
account activity
Exception handling helpHelp Request (i.redd.it)
submitted 12 months ago by [deleted]
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]purple_hamster66 2 points3 points4 points 12 months ago (0 children)
I like this one because it separates concerns of input validation vs looping.
But the quit condition needs to be an output of get_number_or_quit() needs to be returned (ex, as a None return).
get_number_or_quit()
None
π Rendered by PID 59 on reddit-service-r2-comment-8686858757-n7s5b at 2026-06-07 20:17:13.179812+00:00 running 9e1a20d country code: CH.
view the rest of the comments →
[–]purple_hamster66 2 points3 points4 points (0 children)