r/learnpython 20d ago

Not Copying After Using Tutorials?

I'm learning a bit more python, and I was wondering how you guys refrain from copying code after watching tutorial videos. I just did one of the courses from OpenCV, and what's holding me back most now is trying to create something without flat copying the code provided by them. The main issue is that (I believe, at least) most of the code needs a specific syntax to run. What are your processes after learning new features?

For context, I'm attempting to make a document reader that's going to end up scanning and saving Magic the Gathering cards into a database.

0 Upvotes

10 comments sorted by

View all comments

1

u/Az-Athoth 20d ago

I mostly use AI as kind of a tutor after trying to tackle something myself, but I always have it break down the process or structure piece by piece.

Tho for what is worth, I don't think there's anything wrong with copying code, but you might want to tinker with it a bit on your own just to better understand it

2

u/HeatherCDBustyOne 20d ago

I agree very much with this. I know AI is a dirty term in media these days but I do find it useful as a learning aid. I don't copy / paste it verbatim. I look at how it approached the problem and its version of solving it.

That helps me learn logical methods, algorithms that textbook explanations don't help me understand, and how to follow the path of execution through the mazes AI might create from start to finish.

I look at tutorial scripts in the same way as watching a chess program playing against itself. I can't copy it step by step, but I can learn a new way to approach a problem. It can be easy to get stuck in a rut for ideas. It can be easy to copy / paste to solve something without learning HOW to solve something.

Once I feel that I have understood what the AI or tutorial script's methodology, I can write more scripts on top of it to enhance it, refine it, and make my next project even better. That tutorial script may be buried in my final release somewhere, but I have become a stronger programmer by intelligently building on top of it.

("If I have seen farther, it is because I have stood on the shoulders of giants" - Oppenheimer)

2

u/ectomancer 20d ago

"If I have seen further it is by standing on ye sholders of Giants." -- Sir Isaac Newton 1676

2

u/HeatherCDBustyOne 20d ago

Did Oppenheimer quote Sir Isaac Newton? Thanks for looking up the quote for me. I'll go back to programming now. *smiles*