r/learnpython • • Aug 29 '26

Getting into python

10 Upvotes

Hi guys and girls!
I am currently new into python.
I am now on the 2nd hour of a 12 hour course that seems to be good.
Can you give me some good tips to learn it?
Maybe some coding games or fun projects🤔

Appreciate it!


r/learnpython • • Aug 29 '26

Expectations for absolute beginners

2 Upvotes

Hi all, I have maybe a hard question and definitely specific to a personal circumstance, but any perspective would be helpful.

I am a first year PhD student studying immunology, my advisor has signed me up for a stats course in the Biomedical Engineering department. Unfortunately, this class requires proficiency in R, python, or matlab, which neither my advisor nor myself new about. As my title mentions, I have zero coding experience, but recognize how important of a skill it is to have. Would it be possible to teach myself enough about python while taking the stats class concurrently? or is learning the language too tall of a task? I will definitely be reasonably busy with labwork and other commitments but can most likely allocate around an hour a day to learn, sometimes more.

Any feedback or perspective would be helpful, as I still have time to withdraw and choose a different stats course for this semester.

Thank you!


r/learnpython • • Aug 29 '26

Why Does an Identity Comparison Using id() Evaluate to False?

11 Upvotes

I'm trying to figure out what is going on here. Could it be that the identity operator is separately checking the integer cache range and determining that the integer value returned by id() is outside the bounds of Python's integer caching, which is why it evaluates to False?

x = 256
y = 256

id(x) is id(y)
False

id(x)
94588034274160
id(y)
94588034274160

r/learnpython • • Aug 29 '26

Hexagon in arcade not loading example code

2 Upvotes

I'm using the arcade framework and would like to make a hex map game. The provided tutorial code (on this page https://api.arcade.academy/en/latest/tutorials/hex_map/index.html)does not work for import reasons and I'm wondering:

  1. Is this documentation drift (which I've already seen in other parts of the project) where code has been refactored but the examples didn't get rewritten.
  2. How do you import this part of the library to make the example code work properly
  3. How can I get a manifest of importable components of a library? This could have had it's name changed and I wouldn't know.

Any help would be appreciated.


r/learnpython • • Aug 29 '26

Beginner at 31, restarting my programming journey — is my roadmap realistic for freelancing?

0 Upvotes

Hi everyone,

I’m 31 years old and I’m restarting my programming journey seriously.

I have a BTech in Computer Science, but to be honest, I haven’t built a strong professional career in software so far. I have studied programming before, but I never developed the consistency or practical experience needed to become really good at it.

I’ve now decided to change that.

My long-term goal is not to get a traditional software job or prepare for coding interviews. I want to become good enough to earn through freelancing. Eventually, I’d like to work on larger applications and higher-value projects, and perhaps move toward remote work after I’ve gained several years of experience.

What I’m doing right now

I’ve started learning Python and SQL together.

My current target is to finish the fundamentals of both by September 30, 2026. I’m learning relatively slowly because I don’t want to rush through the basics just to say that I’ve completed them.

After Python and SQL, my plan is to move toward practical development — building projects, learning the technologies required to actually deliver things for clients, and eventually starting with small freelance work.

I also want to learn AI/software development over the longer term, so I’d like my skills to eventually move in that direction as well.

Where I am currently

I’ve already studied some programming in the past, but I’m treating this almost like a fresh start because I want to make sure my fundamentals are actually solid.

Right now I’m working through Python fundamentals and SQL, practicing rather than just watching tutorials.

I’m also starting to use GitHub and want to gradually build a portfolio of projects instead of collecting courses.

What I’m unsure about

I have a roadmap that I’m following, but because I’m relatively new to the industry, I don’t know whether I’m prioritizing the right things.

I don’t want to spend the next 2–3 years learning technologies that sound impressive but aren’t actually useful for freelancing.

So I’d really appreciate advice from people who are already working as developers or freelancers.

If you were starting again today with my background and my goal of eventually making a living through freelancing:

  1. Would you change anything about this approach?
  2. What should I learn after Python and SQL?
  3. Which skills are actually valuable for getting the first freelance clients?
  4. Should I start freelancing as soon as I can build simple useful applications, or wait until I’m much more experienced?
  5. What technologies should I avoid spending too much time on as a beginner?
  6. What mistakes did you make when you started freelancing that I should avoid?
  7. At what point would you say someone is genuinely ready to start charging clients?

I’m not looking for someone to give me a complete roadmap from zero. I mainly want real-world perspective from people who have actually worked in the industry or freelanced, so I can compare that with the roadmap I’m currently following.

Thanks in advance to anyone willing to share their experience


r/learnpython • • Aug 30 '26

How do I install python packages with pip effectively?

0 Upvotes

Ive been trying to use pip to install packages for my projects, but I keep getting errors, im not sure if I need to set up anything specific first


r/learnpython • • Aug 29 '26

Where to Continue Python After Clearing the Basics

0 Upvotes

So I have been learning python from the well-known book 'Python Crash Course', I have completed it in the past few months yet I don't know where to continue from. Is there any way I could find some online course and all. I have tried the 'Beyond the Basic with Python' and am currently also doing some problems for practice yet I need a main 'Source' to do my learning and gain in depth knowledge and broaden my knowledge and thinking capabilities. Any useful suggestions are accepted and kindly give some advice for me at this stage.


r/learnpython • • Aug 29 '26

Do I need to install Visual Studio code to run this on a Mac?

0 Upvotes

Hi all,

In short - sorry for the idiot level question but I didn't realise I could even consider this until the other week. Basically the Penalty Blog site has a Dixon Coles model in Python, I'm in a local Football Prediction pool - and it just makes sense to me to bench test this against that.

Had a long chat with Gemini to handle the specifics of the code I'd be using - but one thing it did flag was needing Microsoft Visual Studio Code to do everything I was intending on doing. I have no issue with using that but is it definitely needed on a Mac?


r/learnpython • • Aug 29 '26

Problem with np.piecewise

0 Upvotes

Might be a bug

def get_some_func():
  a, b = ...
  flow = lambda x: ...
  fmid = lambda x: ...
  fhi = lambda x: ...
  return lambda x: np.piecewise(x, [x < a, x > b], [flow(x) , fhi(x) , fmid(x) ]

x1 = ... # some float less than a
myf = get_some_func()
>>> myf(x1)

returns fmid(x1)

is there a bug or do I overwelm np.piecewise with this?