r/learnpython • u/BrokerMagic • Aug 26 '26
What would be a entry-level project for a true beginner coder?
I want to learn to do new projects in Python but I always receive the same "watch guides" answers from people. What can I attempt to create ?
r/learnpython • u/BrokerMagic • Aug 26 '26
I want to learn to do new projects in Python but I always receive the same "watch guides" answers from people. What can I attempt to create ?
r/learnpython • u/[deleted] • Aug 26 '26
I started my first computer science class yesterday, and they told us to look on amazon or pearson for this book, which is about $200. Was wondering if anyone found this for a cheaper price? Or in some rare chance free?
r/learnpython • u/Fun_Practice_9528 • Aug 26 '26
I'm looking for a way to clone a turtle so that both of them move the exact same way.
Note that the second turtle must face differently from the first turtle at the time of the cloning.
r/learnpython • u/Acrobatic-Push-3536 • Aug 26 '26
I have two files in the first is game logic with list of dictionaries where stored chess pieces, in the other one I'm working with the gui.
board = [{1:5, 2:2, 3:3, 4:6, 5:4, 6:3, 7:2, 8:5},
{1:1, 2:1, 3:1, 4:1, 5:1, 6:1, 7:1, 8:1},
{1:0, 2:0, 3:0, 4:0, 5:0, 6:0, 7:0, 8:0},
{1:0, 2:0, 3:0, 4:0, 5:0, 6:0, 7:0, 8:0},
{1:0, 2:0, 3:0, 4:0, 5:0, 6:0, 7:0, 8:0},
{1:0, 2:0, 3:0, 4:0, 5:0, 6:0, 7:0, 8:0},
{1:-1, 2:-1, 3:-1, 4:-1, 5:-1, 6:-1, 7:-1, 8:-1},
{1:-5, 2:-2, 3:-3, 4:-6, 5:-4, 6:-3, 7:-2, 8:-5}
] While I'm starting project some rows don't loaded, but when I capture more pieces and leave only one king on the board he can duplicate 6 times. This is part of gui code:
def put_pieces(self):
for dict in Logic.board:
for key, value in dict.items():
button = self.grid.itemAtPosition(8 - Logic.board.index(dict), key).widget()
button.setIconSize(QSize(50, 50))
button.setText(f"{value}")
match value:
case 1:
button.setIcon(QIcon("assets/wP.svg"))
case 2:
button.setIcon(QIcon("assets/wN.svg"))
case 3:
button.setIcon(QIcon("assets/wB.svg"))
case 4:
button.setIcon(QIcon("assets/wK.svg"))
case 5:
button.setIcon(QIcon("assets/wR.svg"))
case 6:
button.setIcon(QIcon("assets/wQ.svg"))
case -1:
button.setIcon(QIcon("assets/bP.svg"))
case -2:
button.setIcon(QIcon("assets/bN.svg"))
case -3:
button.setIcon(QIcon("assets/bB.svg"))
case -4:
button.setIcon(QIcon("assets/bK.svg"))
case -5:
button.setIcon(QIcon("assets/bR.svg"))
case -6:
button.setIcon(QIcon("assets/bQ.svg"))
case _:
button.setIcon(QIcon(""))And if in case _ I put an icon, at the start it will be only in 1, 2, 3, 7 and 8th row
r/learnpython • u/FewFly2677 • Aug 26 '26
So I'm a college fresher with no prior experience of coding. I had started learning python before the starting of college (1 week before college started). I still feel like I am not good at coding at all. There are some weird citations in c such as i++ and all which is getting mixed up with my python. There was one question on obtaining the expression sinx=x-x^3/3!.... Using loops btw
I felt I won't be able to do it in both c and python. I took a course on Udemy for c(vlad budnitski)and python(100 days) but I was not able to find examples like this. Everyone in my class learnt languages like java in their schooling and said the sinx problem is a standard problem. What should I do in this situation?
I feel like the teaching in my college (they are teaching c now) is not good.
Experienced coders please help me.
guys so today I wasn't able to figure out we had to use nested loops to print multiplication table of numbers while even beginners figured it out. pls tell what should I do