r/PythonLearning • • Aug 01 '26

Help Request How do I do it so that the position of a rect depends on the position of the last placed rect in a class?

1 Upvotes

I want to make platformers where rects are generated randomly but not 100% random. How do I do titel? Or is there a better way?

Edit: in pygame.


r/PythonLearning • • Aug 01 '26

Help Request Help

Thumbnail
github.com
1 Upvotes

Greetings people, I have a help request for you all that I am not getting the use of the library Steamlit & NiceGUI. From the side of NiceGUI I cannot style it to my liking and the documentation is complicated that

And it color palette is bugging me out so I need a help. Here's a NiceGUI and steamlit link of GitHub.

https://github.com/EmadFahim134/Chuchu-Ai

&

https://github.com/saqibvow/chatbot-in-python


r/PythonLearning • • Aug 01 '26

I wanna learn python

0 Upvotes

People usually say Python is an easy programming language, but as someone with no programming experience, I find it really hard. Can you guys tell me where I should start? Also, what benefits will I get from learning Python?


r/PythonLearning • • Aug 01 '26

Showcase Python Developers: What's one keyword that completely changed how you saw Python?

Post image
5 Upvotes

It's always interesting how one small language feature can completely change the way you think about Python—not because it's flashy, but because it unlocks a different way of solving problems.

Whether it was something simple like with, yield, nonlocal, match, or something more obscure, I'd love to hear why it changed your perspective—and what you were doing before you discovered it.


r/PythonLearning • • Aug 01 '26

Help Request Whelp. What's the correct docstring format?

Post image
4 Upvotes

I'm publishing my first python package and wanted to confirm the correct docstring format to conclude the documentation. The image above summarizes my search online, AI or otherwise.

PEP 257 appears to prefer option 2 (the left in the image) but I find option 1 out in the wild so much more often. So what's it?

Ohh and yeah, neither is correct because the first line should be a summary and what follows should be a more elaborate paragraph after a blank line. But I really just want to know whether the text should start of the actual first line after the """ or not. I'm using sphinx if it makes a difference.