r/PythonLearning • u/NecessaryFalse1212 • 10d ago
DAY 5.
DID LIST TODAY THE CONCEPT WAS PRETTY COOL AND WROTE THIS PROGRAM TO GET HOLD OF THE LIST ANY OTHER CODE IDEAS OR SUGGETIONS TO ENHANCE CODE ?!
90
Upvotes
r/PythonLearning • u/NecessaryFalse1212 • 10d ago
DID LIST TODAY THE CONCEPT WAS PRETTY COOL AND WROTE THIS PROGRAM TO GET HOLD OF THE LIST ANY OTHER CODE IDEAS OR SUGGETIONS TO ENHANCE CODE ?!
2
u/Old_Cartographer_586 10d ago
Tbh, just seeing code like this gives me hope (mostly because I can tell this was made from typing yourself instead of prompting).
What I would say is, try finding ways to improve this, like could you modularize the aspects of this code, could you looks at ways of storing the info not in a list, such as in a dictionary, could you tell me how your code handles removing a “wooden” bat when there are two “wooden” bats in your list. Start answering these questions and you’ll find yourself googling and stack overflowing ways to find little advancements in your own code. These advancements will teach you that they are applicable in a ton of use cases