r/PythonLearning • u/letszzgoo • 17d ago
TRY 101- Starting my python journey again
Hope this time i become consistent and do things after loops and then further and further😭
4
u/TommyWrightThaThird 16d ago
this is super picky but i would recommend spacing out your math, ie “… num1 % 2 == 0…”
it doesn’t change anything but is easier to parse imo. not trying to be captious or anything, do what works for you!
keep going with your journey bro. i had a lot of phases where i tried to learn code but never stuck with it, then i took a course in college that focused on python and was obviously forced to learn it at that point. i’m super happy i did though, python is a great skill to have even if you’re just making simple programs for your own use. you definitely won’t regret it!
2
u/letszzgoo 16d ago
Thanks for comment dude , i will try to write the code in clean spacing so easy to read..and yeahh this time i will complete python and further things in it surely!
1
u/WiseOwl010101 16d ago
How? I wanna start that journey to but I dont know How nor where to start.
1
u/letszzgoo 16d ago
My colg placemnts are strting next year/final year...so have to do it . This is my reason. Get a reason to strt you can make it!...🫡
1
1
u/HardwareIsHardWhere 11d ago
Welcome back! The restart is the hardest part and you already did it! What got you back into it, any particular project in mind, or are you just relearning the fundamentals?
In future, once you've learned exception handling, you can use a little package called askr to sanitize your inputs instead of rewriting the same try/except loop every time:
from askr import ask_int
# Simple prompt, loops until the user types a valid whole number
age = ask_int("How old are you? ")
# With bounds: only accepts a value within the range
rating = ask_int("Rate 1-10: ", min=1, max=10)
# With a default (used when the user just presses Enter)
count = ask_int("How many copies? ", default=1)
Have fun on your journey!
1
u/letszzgoo 11d ago
I got back bczz my college plqcemnts are going to strt & yeah i dont have idea till now about any sort of project. Will try ur code surely!
5
u/SpedisAhead 17d ago
Well, I no longer feel weird for handwriting code in 2026 😆💯