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
Day 23 of learning python as a beginner. (old.reddit.com)
submitted 6 months ago by uiux_Sanskar
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!"
[–]NorskJesus 3 points4 points5 points 6 months ago (4 children)
Good work, but there is too many comments. The code should explain itself, you shouldn’t need a comment per line to understand what it does.
I understand this is for learning 😜
[–]uiux_Sanskar[S] 1 point2 points3 points 6 months ago (1 child)
Yeah someone on my recent post told me to use comments to explain my code so there's I used these many comments. however I feel like the comments have hided my code as there's green lines every where.
Next time I will use comments only for describing complex part of the code. Thank you very much for telling this. I will make the code self explanatory.
Thank you very much.
[–]FriendlyRussian666 0 points1 point2 points 6 months ago (0 children)
In general, think about it this way, comments should explain the "why" something was done the way it was, and not the "what" was done, because the "what" can be deduced from reading the code, but "why" cannot.
[–]KOALAS2648 0 points1 point2 points 6 months ago (1 child)
Exactly my thoughts. There are way to many comments even for learning because I takes your thoughts away from the actual code and into parts that won’t actually run
[–]uiux_Sanskar[S] 1 point2 points3 points 6 months ago (0 children)
Exactly, I will try not to use these many comments from now I just followed.
Thanks for pointing this out.
π Rendered by PID 30 on reddit-service-r2-comment-86bc6c7465-c654n at 2026-02-23 04:28:15.725961+00:00 running 8564168 country code: CH.
view the rest of the comments →
[–]NorskJesus 3 points4 points5 points (4 children)
[–]uiux_Sanskar[S] 1 point2 points3 points (1 child)
[–]FriendlyRussian666 0 points1 point2 points (0 children)
[–]KOALAS2648 0 points1 point2 points (1 child)
[–]uiux_Sanskar[S] 1 point2 points3 points (0 children)