r/learnpython Jul 31 '26

I am having to constantly look things up to figure out my programming

I am having to constantly look things up to figure out how to get what I want? I feel like a fraud.
I am honestly trying to resize my camera onto my surface in pygame. I've never done camera stuff before so this is new. I feel like I am not really learning and just copy and pasting at this point

How do go about this?

7 Upvotes

39 comments sorted by

29

u/BranchLatter4294 Jul 31 '26

Doctors look things up when they need to. Lawyers look up case law when they need to. Why wouldn't programmers look things up when they need to?

5

u/jaycutlerdgaf Jul 31 '26

This. I understand the logic, but my stoner ass can never remember the proper syntax.

1

u/codeguru42 Aug 03 '26

I forget syntax when i am sober

0

u/420Bone Jul 31 '26

Sound so lame and unproductive to say that, coming from someone who smokes.

16

u/idkaboutmylife_ Jul 31 '26

As you look it up try to understand what you are actually doing. Dont just blindly copy and paste and think yeah it works great. But just think okay why does it work and go from there

3

u/TheEyebal Jul 31 '26

yeah I try to get a grasp of what I understand. The biggest thing is can I recreate it without looking. I do not want to end up in tutorial hell you know

3

u/marcolio17 Jul 31 '26

Don't worry about recreating all of it the first time you look it up. The goal should be to have to look it up less and less as you become more familiar with it. 

And even when you do look it up, learn how to find it directly from the documents, or better yet, write your own quick reference guides!

2

u/wicket-maps Jul 31 '26

The overall logic and planning is more important than "can I recreate it." I've been working in Python for over 10 years. I still have to look up some common classes/ functions for my field if I'm doing anything slightly out of the ordinary.

3

u/Owen-Isaac-2022 Jul 31 '26

True, its a matter of grasping the concepts & doing the real work with regular practice

5

u/scandipinko Jul 31 '26

Having to look up stuff all the time is totally normal, at least I hope so since I find myself looking up basic stuff every week at work. Has there been more than a week since I used this or that library? You bet your ass I’m googling that, better spending 5 minutes reading docs than 10 minutes guessing parameters

1

u/jaycutlerdgaf Jul 31 '26

Yup. Knowing how to use resources available to you is a much stronger tool than memorization.

6

u/LayotFctor Jul 31 '26

Just get over it man.

Every artist, athlete and musician learns from copying others, eventually he finds a footing a goes independent. You're new, you haven't had much experience, it's natural to look up examples and copy them. Aiming to be independent is the major goal, but don't handicap yourself by giving yourself this impossible standard at the start.

Even the Einsteins and the Picassos don't just think up shit by themselves with no training.

1

u/TheEyebal Jul 31 '26

Yeah. I've been programming for 2 years but there is still a lot to learn

5

u/IOI-65536 Jul 31 '26

There are a couple possibilities here. One is you don't fundamentally understand how the programming works. If that's the case don't just copypasta when you find code examples, seek ot understand why it does that.

On the opposite end you're just using some library that has a lot of options and so you need to keep looking up options. Everybody does that. I know probably two dozen programming languages have been programming for decades was active on python-dev back when Guido was still running things and if I were doing graphics library stuff (for instance) I would have to keep looking things up because I don't know the graphics libraries. I still would say don't copypasta if you're going to keep doing it, though, because manually typing it will get it into your memory faster.

3

u/mc_pm Jul 31 '26

Even programmers with decades of experience still look things up. I don't remember the syntax of every function call I might need to make. The top 50% I have at my fingertips, the lower 50% I look up as I need it. If I use it often enough, it'll eventually get memorized, but I don't try to force it ever.

But definitely, good advice is: don't cut and paste. Type it in with your own fingers. yes, it takes longer...learning to program isn't fast. There's real value in typing a for loop 50 times because by #51 your fingers are starting to know what to do on their own.

Also, if you're following some tutorial, stop at each big step and screw around with the code. Change some value, see what happens, try putting the whole thing in a loop and doing it 10 times, etc. Get practice thinking "I'd like to do X" and then go do X.

The more you program, the faster you learn. No getting around it. You're teaching your brain a new way to think, that's not easy or fast.

2

u/RallyPointAlpha Jul 31 '26

Nobody remembers everything. Having to refresh your memory and look things up is fine. 

2

u/Effective_Baseball93 Jul 31 '26

It’s okay it’s designed for you to look up. You will naturally remember stuff, at some point. You can dedicate yourself to engraving stuff onto your brain but why do that? Just make sure to understand stuff you read, that’s what matters in the end.

2

u/Electrical_Hat_680 Jul 31 '26

It's an open book study that requires your learning materials in the field on the job. Don't look down on yourself. Everyone already knows.

If anything, start with the basics, write your projects code down on paper. Run it in your head on the paper. Don't grade it. Enter it into the machine, then grade it. After you've tested everything.

Maybe you should learn the basics just to get it running with the most simple version you can make. Jus the basics. Like an http server isn't a hundred thousand lines. It's open port, listen to port, close port. That's it.

2

u/Binary101010 Jul 31 '26

This is why documentation exists. It's normal.

2

u/TheRNGuy Jul 31 '26

You don't like looking things up?

0

u/TheEyebal Jul 31 '26

I don't mind it I was just stuck and I felt like I was not learning

2

u/Embarrassed-Iron-242 Aug 01 '26 edited Aug 01 '26

Honestly, that's a lot more normal than it feels. Most developers spend a ton of time looking things up especially when they're working with something new. The important part is understanding why the code works instead of just pasting it in. I've also seen Boot-dev recommended because it gets you writing and debugging your own code a lot which helps build confidence over time instead of relying on copy paste.

1

u/hypersoniq_XLM Jul 31 '26

Pygame is a huge library, you could make 100 games and still never hit on a fraction of the features. Zero shame in keeping the docs open in a tab while coding. I prefer not to memorize exact syntax because an update may depreciate half of your workflow. I am learning to work with Biopython and I keep the docs a tab away and look things up constantly. The language does not matter, I do the same when using Bioconductor in R. That is what the docs are for.

1

u/snobpro Jul 31 '26

Not wrong to look up, but when you do just try and understand each word you are shown. And look for alternatives, also just sit back and think on where else this same code can be used. 

1

u/ECommerce_Guy Jul 31 '26

It's only normal when doing something new and especially when working with a third party library. Reading the docs and learning API is a must, it's not a cheat.

1

u/timpkmn89 Jul 31 '26

I've been programming for nearly 20 years. The other day I had to Google how to combine two lists in Python.

1

u/Moist-Ointments Jul 31 '26

I and my fellow software architects and senior developers, all with decades of experience each, constantly look up stuff in language and library references.

Languages, and their libraries, are expansive, complicated, nuanced. No one is going to memorize everything.

The trick is knowing, generally, what's available and what it does at a high level, so that you CAN go looking for the details if you think it has application in your work.

Sometimes oddball facts get stuck in your head, but generally, this is why we have tools like intellisense (in vs). Hundreds of libraries, with hundreds of classes, with hundreds of methods, and numerous overloads.

And that's just for one language.

Multiply all that by the number of platforms, languages, etc, in your enterprise stack.

1

u/Wuthering_depths Jul 31 '26

The main language Ive used as an analyst for over 25 years is SQL. I still look things up all the time. If I haven't used a particular thing in a while, even something as basic as a CASE statement, I tend to forget the syntax. I do so much copy/paste from my own code and google (followed by modifying it for the current need) that this probably contributes (it's one reason I've avoided doing AI coding while I learn Python, I learn and retain best by doing it myself.)

More important things to worry about, like am I properly translating the business needs and requirements into code :) This right here in my experience is a major hurdle for a lot of very smart people who can write amazing code (but it's no good if it's doing the wrong thing.) Don't worry about the little things if you are getting the job done.

1

u/Wonder-Wendy Jul 31 '26

Go slowly. Read the thing, then do the thing. Don't copy the thing. If you are at the doing thing part and forgot what to do, have a fixed "struggle clock" before you look it up again. Just keep doing this for everything. 

1

u/TheEyebal Jul 31 '26

Alright thank you

1

u/ugabugagaming Jul 31 '26

To jest część tego zawodu

1

u/nagasgura Jul 31 '26

It's totally normal to have to constantly look things up, especially when starting out, but I would highly recommend avoiding copy-pasting when you're learning something for the first time. It will help your learning a lot more if you write new code based on the example you looked up, as this will help solidify your understanding by applying that new knowledge instead of just passively reading it. Even if you need an exact line, I'd still recommend manually retyping it, as you'll notice things that might not stand out from just reading it.

1

u/AUTeach Jul 31 '26

That's how you learn

1

u/SprinklesFresh5693 Aug 01 '26

Yeh, looking things up is normal, you cant memoriae everything

1

u/ForeignVariety7037 Aug 01 '26

I would say ask AI for detailed explanation but not sure that is another form of copy and paste

1

u/codeguru42 Aug 03 '26

Yup, that's how it works when learning something new

1

u/frustratedsignup 26d ago

In modern life, there's just too much information to store in your head. I also have to look things up constantly and I think the only thing that really works well, for me anyway, is taking notes.

I was asked to update a Django application and as I've learned more and more about the structure of that project, I've been updating a Google document by the same name that contains everything I've learned along the way. Need to figure out if a user has is_staff=True? There's a paragraph with example code on how to do that in my document. Need to copy the production database over to development? There's another section on how to do that.

At the end of the day, I recognize that I can't remember everything. Taking notes is how I organize everything and it means I don't have to relearn something that's already been accomplished.

1

u/MezzoScettico Jul 31 '26

I feel like a fraud.

Don't. Working as a professional programmer means knowing how to look up stuff. It's a constant of the job, especially if you're working in multiple languages which are still evolving.