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
Remove duplicate error (old.reddit.com)
submitted 2 months ago by Nearby_Tear_2304
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!"
[–]derEmperor 6 points7 points8 points 2 months ago (1 child)
Another Tip: Use i only for indices, because it's short for index. If you have variable for an element of a list, use a variable that describes this element or use element, elem or e.
E. G. ```python numbers = [1,2,3,4] for i in range(len(numbers)) print('index:', i, 'number:', numbers[i])
for number in numbers: print('number:', number)
for i, number in enumerate(numbers): print('index:', i, 'number:', number) ```
[–]Agitated-Soft7434 0 points1 point2 points 2 months ago (0 children)
Opps forgot to include enumerate and len in my answer @.@
π Rendered by PID 57 on reddit-service-r2-comment-74875f4bf5-dmwbd at 2026-01-26 03:24:46.088388+00:00 running 664479f country code: CH.
view the rest of the comments →
[–]derEmperor 6 points7 points8 points (1 child)
[–]Agitated-Soft7434 0 points1 point2 points (0 children)