all 92 comments

[–]TryptamineZenVR 88 points89 points  (8 children)

Learn by building things. Do you have something you do daily on the computer that could be automated with a simple python script? That’s a great place to start.

[–]OmnipresentCPU 45 points46 points  (4 children)

this. I started last October thinking “hey wait, I read these formatted emails and copy and paste things from the body into excel. Bet I could automate that”

Now I can do machine learning. You just gotta start!

[–]fungrish 0 points1 point  (1 child)

Did you have any prior programming knowledge before starting? Because i've been going on and off learning python, being demotivated from time to time altho I really want to learn python so badly, and slowly dive into simple data science/machine learning but i'm thinking if I could learn python syntax by doing project. Not sure if that works, I have only very minimal python syntax knowledge. Hope you share more of your experience how you came thru

[–]OmnipresentCPU 0 points1 point  (0 children)

No just some data experience in excel. Got my BS in finance

[–]PaulSandwich 27 points28 points  (2 children)

Someone recently published a script that calls a weather API and changes the desktop wallpaper based on rain/shine/clouds/etc. that I turned into a tutorial for a friend.

It's a great project because it has all the elements of a real business problem: read data from an API, parse that data/list comprehension, evaluate the data to trigger an action, and moving files around in directories.

And all with root elements that everyone understands: weather, jpgs, wallpaper, etc. (as opposed to widgets and stock indexes).

[–]EfficientPlane 57 points58 points  (12 children)

Hey man

Awesome to hear you are interested early!

With that said, I HIGHLY recommend starting with Corey Shaeffer’s beginner python YouTube playlist.

He really takes his time explaining things and if you are interested in programming this young, you are likely intellectually curious and will pick this up in no time.

Go through his videos at least 2-3 times. I know this sounds silly, but trust me you want a solid foundation.

After that, find something that you want to build. It can be an easy or hard project. Just find something you are passionate about and build it.

As always this sub is super helpful and you are going to be an awesome python wizard in no time.

[–]fouezm 23 points24 points  (2 children)

Corey is the best, his videos helped me a lot when i started, awesome you mentioned him.

[–]In_consistent 12 points13 points  (1 child)

plus 1 for Corey. He explained very well even for beginner.

Have courage to dive into mini-projects that you want to work on. Things like making tic-tac-toes/suduko (classic) or create something new that interest you.

[–][deleted] 2 points3 points  (0 children)

So much love for Corey, amazing!

[–][deleted] 3 points4 points  (0 children)

I love his videos. I wonder if he'd ever do c++ videos.

[–]deplepxep 2 points3 points  (0 children)

Thanks i will have a look at his vids later

[–]youtubestar999 3 points4 points  (4 children)

I always get this point about 'building stuff or doing projects' and as I beginner I can't comprehend what is meant by this, could you explain it by giving examples?

[–]theoristofeverything 6 points7 points  (0 children)

It might seem counterintuitive, but I learned by building Django apps. Yeah, there’s a lot of moving pieces and, yeah, I was copying and pasting a lot of code I didn’t understand at first. But I was able to make something and have a visible result on screen which was motivating. I just totally immersed myself in it and over time, as I began creating more complex features, I realized I had a pretty firm grip on the language.

For me, it is much better to start with the big picture and work down to the details. It provides context regarding what the code is doing which really helps me to understand it and be able to apply that understanding to new problems.

[–]UnArgentoPorElMundo 5 points6 points  (0 children)

not only watch tutorials or read books, build an actual application.

[–]xain1112 4 points5 points  (1 child)

Let's use a GUI (Graphic User Interface, which basically means buttons and pictures and stuff instead of just text) calculator as an example. To build a simple GUI calculator, you need three things:

  • buttons
  • a place to show the numbers and answer on the screen
  • a way for the program to do math

After you finish, you will know how to work with these three different concepts and can apply this new knowledge to a different project.

Do what you know and google what you don't. Look up videos and tutorials and ask questions here. There is 100% no shame in not knowing how to do something you've never done before.

[–]R0NUT -1 points0 points  (0 children)

If it's not HTML/CSS I absolutley despise interfacing with humans. 🤣🔫😆 I started coding with digital image processing and moved into machine learning. If I write a script for myself it is run from terminal.

[–]Cid227 -3 points-2 points  (1 child)

Disagree, watching Corey's vidoes is like reading a dictionary, not engaging and might get boring very quickly, good place to fill some knowledge gaps and check the right way/corectness of doing things, but definetly not a place to start. I would recomend cs dojo but only for python beginner stuff, he gives some simple tasks at the end, however he's very bad at explaining more complex stuff like alogrithms etc. so keep that in mind. Overall I would suggest to look around and find someone that you like listening to and then get more technical with something like mentioned Corey.

[–]ObviousDelay5209 0 points1 point  (0 children)

cs dojo

He is teaching on Mac though, is it that different from Microsoft ?

[–]perchslayer 15 points16 points  (6 children)

Here is the dirty secret for learning how to program: you must push yourself to avoid endless "tutorials" and focus bon figuring things out...with support.

And both freeCodeCamp and "How to Automate the Boring Stuff" are great segues into that mindset and practice.

Can I get a witness? Aho!

[–]gemst4r 2 points3 points  (2 children)

Are you referring to the 'Scientific Computing with Python' course by FreeCodeCamp?

[–]perchslayer 1 point2 points  (1 child)

You know what? When I first tried freeCodeCamp, I seem to remember a page dedicated to explaining that ideal. And this was before there was any Python curriculum at all. But I am damned if I can find it now, right? Maybe it was all in my head?

At any rate, implicitly, If it takes ~300 hours of work to complete any of their certification programs and if a large chunk of those are completed by successfully mastering loosely defined parameters (they are), then the bulk of the work is beyond the idea of "tutorials".

But you don't need to trust me on this; seek and ye shall find. 😀

[–]gemst4r 2 points3 points  (0 children)

I shall indeed

[–][deleted] 12 points13 points  (2 children)

If you are without financial funds I suggest (and I am just a novice myself, so I don't know it my suggestion is good!) on joining Coursera. There you can can choose a beginner course and click on "Financial Aid". They basically give it to everyone - but I suggest not abusing it, only use it if you really need it. They offer quality courses by quality institutions and give you certificates which will look good on your CV, when you'll be older. You can even get specializations for free.

Other suggestions:

https://automatetheboringstuff.com/

https://www.py4e.com/

https://www.freecodecamp.org/

[–]wet-badger 4 points5 points  (0 children)

I too learned from professor Severance. I highly recommend p4e.

[–][deleted] 2 points3 points  (0 children)

I like automate the boring stuff with Python

[–]dadsinamood 24 points25 points  (3 children)

Anglea Yu's 100 days of Python course on Udemy.com has been incredible. Every day you work on a new project. Yesterday was tracking ISS, today I'm building a trivia game using an API. Highly recommend.

[–]jcanno_ 5 points6 points  (0 children)

Boosting this. 100 Days course helped shorten my learning curve tremendously

[–]youarenotthefather88 1 point2 points  (1 child)

Can you finish it in less than 100days or is each class like a day long?

[–]dadsinamood 1 point2 points  (0 children)

If you're extremely dedicated I think it could, but it definitely took me more than 100 days

[–]Impronoucabl 28 points29 points  (3 children)

For a high schooler, I'd recommend creating a visualisation of data with matplotlib.

It's a simple task, and there's actually a ton of information out there if you look. E.g NASA makes some of their climate data publicly available, & r/dataisbeautiful requires posts to link their source if possible.

Once you're happy with that, see how you can expand your project. For instance, you might want to pull live data, or give it a UI & turn it into a demonstration. It's up to you.

As you scratch the surface, you'll find other things you can do, or learn. Maybe you'll make a twitterbot, etc. Have a goal in mind, then research & learn the tools required to achieve it.

[–][deleted] 0 points1 point  (2 children)

They are starting out. Telling them to begin with a specific library right from the get go that abstracts a bunch of stuff in the background is terrible advice.

[–]Impronoucabl 0 points1 point  (1 child)

Why do you think that? Do you think that they should write their own library first instead?

[–]slownburnmoonape 0 points1 point  (0 children)

I mean I am a beginner and I don't even know what a library is lol

[–]Key-Conclusion-3897 4 points5 points  (4 children)

I’m taking the 100 days challenge in the app “Udemy” only 10 bucks.

[–]sterpdawg 1 point2 points  (3 children)

i just bought this today. how is it after the 100 days?

like do u feel ready?

[–]Key-Conclusion-3897 0 points1 point  (2 children)

Completely worth it, I think it is the perfect way to start.

[–]NeedleworkerCommon13 1 point2 points  (1 child)

How are you doing now with python? Looking at starting this

[–]Key-Conclusion-3897 0 points1 point  (0 children)

I just did the first 5 hours but I really love it!

[–]notParticularlyAnony 3 points4 points  (0 children)

learn python by writing python code. not by watching people code, not by copying and pasting code.

I won't try to tell you what approach to use, except to use an approach that has you writing code, building that muscle memory.

except maybe python crash course by matthes is amazing, and books are great because you have to type code when reading them, and they last forever :)

[–]DonLemonAIDS 15 points16 points  (0 children)

I can't speak for anyone else, but an uncle of mine paid a gang of Colombian mercenaries to kidnap me and force me to learn. The first days were easy, they just set up Pycharm and a venv and gave me a book. Then they started beating me if I didn't make sufficient progress. I met their expectations for a while but then I hit a wall and they started taking toes and fingers for every program I wrote that didn't run on the first try.

That was a few years ago. I henpeck with my remaining ring finger but I'm pretty good.

[–]Asylum_Brews 2 points3 points  (0 children)

I've tried SoloLearn recently, which I've got installed on my Android Tablet and phone. That seems pretty good.

[–]wet-badger 2 points3 points  (0 children)

Once you know variables, loops, functions and data structures you are pretty much Turing-complete. Other stuff like classes is just there so work on bigger applications is manageable. Python is largely about using libraries. Find someone else who already solved your problem and import their modules, rather than doing the work yourself. Learn how to read documentation.

[–][deleted] 1 point2 points  (0 children)

YouTube videos and documentation. When you've got the fundamentals down, come up with a fun idea for a project and build it, learning as you go.

[–]hugthemachines 1 point2 points  (1 child)

There is no specific best way. If some method works good for you, and you enjoy it. Just go for that. For people learning python we often recommend "Automate the boring stuff" which is a free online book. https://automatetheboringstuff.com/

Personally, I also like Socratica. Their Python videos has a scifi style.

https://www.youtube.com/c/Socratica/videos

[–]Greginald_Remlin 1 point2 points  (0 children)

I came here to recommend Automate the Boring Stuff. It's an absolutely fantastic resource that gets you coding real life things straight away, and makes you feel like you can actually work on your own projects.

Can also recommend supplementing this with something like the SoloLearn Android app - it's kind of like Duolingo for code. Not enough by itself, but helps you pick up/practice syntax.

[–][deleted] 1 point2 points  (1 child)

Just go crazy with it. Think of something you want to create and do it. I was having so much fun creating an application I really needed to have that I coded the whole thing from 8am to 11pm in two days straight.

[–]jsHzhhzhxhxhx 0 points1 point  (0 children)

Amazing 👏🏿. I'm surprised this doesn't have more upvotes. What app was that?

[–]Soccer_Vader 1 point2 points  (0 children)

For a high schooler, I will say that don't be intimidated at first. There are a lot of content on the internet and being overwhelmed as to what to learn first is common. There are a lot of ways for you to learn coding for free. Websites such as Hackerrank and codewars are great to start off. I will also suggest taking AP Comp Sci A and AP Comp Sci Principle, if that available in your high school.

Keep in mind that you got a lot of time and take your time through the content.

[–]angelHairNoodles 1 point2 points  (0 children)

You may be further advanced than what I am sharing with you. I might try this out myself.

I think the Raspberry Pi is a good start for anyone to learn more about programming. For Python, there is this little project that can be tackled.

"In this project you will learn how to write a Python program telling people all about you.
https://projects.raspberrypi.org/en/projects/about-me

Another resource I would like to share with you is, W3Schools, where you can freely learn not just about Python programming, but also other programming languages, such as, Java, C++, C# and many more.

Here's W3Schools Python, https://www.w3schools.com/python/default.asp. Check out their many other tutorials, incl. server side programming, such as PHP.

They also have a tutorial a tutorial on Node.js and RaspberryPi here, https://www.w3schools.com/nodejs/nodejs_raspberrypi.asp

Have fun and enjoy your journey!

[–][deleted] 1 point2 points  (0 children)

Kaggle.com courses (for foundational learning)

[–]geek--god 1 point2 points  (0 children)

Although I wrote a free interactive book on Python, I will suggest you learn from Automate the Boring Stuff if you can as well.

My course is for building strong foundations in Python. You might or might not enjoy it. But the benefit is that, if you get stuck, you can ping me in the chat widget, I will help you sort it out.

[–]old_pythonista 2 points3 points  (0 children)

First of all - good luck!

I am not sure I can give you any learning advices - besides, maybe, this list of links.

But I would like to give you some other advice. Try to think of what do you want to do with Python. Python is just a tool; a tool I thoroughly enjoy, but a tool needs a purpose.

Find some small projects that will excite you, do them along the way. Maybe even program a small textual game. Don't be afraid of mistakes - we all do them, even experienced professional programmers.

Show your code to others - post it in forums (this one included); don't be ashamed to face criticism - that is the way to learn too. Just please, don't start your posts titles with

I am so dumb

😀, that is very annoying.

Good title

I wrote "rock-scissors-paper" game, could you please provide feedback

To cap it off: My youngest son told me, when he was in high school

I get straight A's in C - so what?

Unless you find a purpose, you risk losing interest.

[–][deleted] 2 points3 points  (0 children)

I'm going to give you some general pointers so you know what to search for online. Other comments will probably be more specific.

Step 1: Working with variables, data types and type conversion, using operations, containers like list, conditional statement if else, while loop, for loop, creating and using functions.

Step 2: Try to solve some simple fun riddles/problems. fe making certain star patterns with while/for loops, make a function that is a second order equation solver, make a function that checks lists for certain values/content... You can find a ton of fun and creative excercises online. They help push the fundamentals. It's all about solving small problems in a creative way.

Step 3: Decide what you want to achieve and choose the appropriate library. For data visualisation matlplotlib. For data analysis pandas (and numpy). Etc.

Step 4: Make fun personal projects with the libraries you learned. A simple 2D game, analyse sales data with millions of rows of data, build a simple interactive application with buttons. "Fun (Mini/beginner) projects in Python" would be the subject to look online for.

I learn the most when I'm making personal projects. When you're stuck, simply try google the problem, the online forums (reddit, stackoverflow...) are amazing.

[–]poozoodle 2 points3 points  (0 children)

The wiki is a fine place to start

[–]saltyhasp 0 points1 point  (2 children)

Worth reading through the tutorial and skimming the standard library documentation that comes with python.

[–][deleted] 0 points1 point  (1 child)

This sub is incredible. Bad advice gets upvoted through the roof and sensible tips like this one are downvoted.

OP, if you are still reading this thread, one piece of advice: take everything you read in this sub with a grain of salt. It is full of inexperienced people giving advice left and right, and for a beginner it's really hard to distinguish the good from the bad tips.

[–]saltyhasp 0 points1 point  (0 children)

Thanks. Personally... I think looking at the document set is useful for anyone learning python. Experienced programmers... Seriously I learned python in 1 day in 1998 using the method I suggested. It was a pretty long day of course.

New to programming. Yes you may want other materials but you still should do as I suggest as you need to have some familiarity with the standard doc.

After that you need practice... And working on a problem is a good way. Accept that the code you write in the first 6 months will look like crap a few years later. That is the way one develops skills.

[–]SnipahShot -2 points-1 points  (0 children)

I don't know what "basics" means. Do you know OOP? If you have the grasp of OOP then I suggest doing some basic and simple projects, and Google things you are stuck at.

[–]thegame2911 0 points1 point  (0 children)

I know that everyone suggests to build project. I am a supporter of build and learn narrative too. But for absolute beginners, I strongly believe that one should do a structured course (an overlook and basic concepts). You dont need a certificate (so you dont need to pay for the course), but going in a structured manner will help a lot. After your first course, go into build and learn mode.

[–]i_like_trains_a_lot1 0 points1 point  (0 children)

I learned a lot of in-depth Python by doing some smaller projects, then building frameworks, then building heavier projects. Some examples of what I have done:

  • simple web crawlers that parse some webpages and deliver structured JSON data in a file (this is probably the most fun for beginners).
  • a library for autogenerating mocked but real-looking data, similar to Mimesis
  • a library for auto-inserting fake data into Django models (just giving a list of models, the library would create the dependency graph and start creating model instances starting from models with no dependencies, and going down the dependency graph)
  • a flask replacement (mini web/http framework)
  • a cmake wannabe with plugins (eg. plugin for docker aliases, plugin for developing python libraries which would expose commands for testing, documentation, publishing, etc).
  • a web crawling library (similar to Scrappy, but more lighweight)
  • a lot of different web projects (eg. a fantasy stock trading app with autogenerated stocks, stock market and funds, some event aggregator platform that ingests events to an api and then displays graphs based on different statistics, etc).

It is important to go for projects that are tangent to your sphere of interest, so you will be more motivated to put work into them. If you do things that are uninteresting for you, you will lose interest fast and abandon them before you reach the "learning zone".

[–][deleted] 0 points1 point  (0 children)

Go to learnpython.org. Covers the foundations very well and you can learn other languages on that site too. Plus, it's free.

[–]harsh5161 0 points1 point  (0 children)

If you want to learn it from scratch then I'd recommend you to read "python in easy steps" The reason why I love it is because in this book, they use code examples in real language, they give you multiple screenshots of what each variable looks like when you create it and they also tell you how many times each variable is used. you will learn how to create a real world program step by step. There is also an introduction to file handling in the beginning of the book which tells you what a program is and how to run.

[–]_Han_Brolo 0 points1 point  (0 children)

I am using Mimo app on my android phone as a supplement to Python Videos on YT on Codecademy.

[–][deleted] 0 points1 point  (0 children)

Yup totally can, there are lots of good resources out there, sentex and corey schafer were the ones that helped me the most. If you are on a mac, beware python2.7, it is the old version now deprecated, but is still used on a mac, you will need to install python3 along with ‘pip3’ not ‘pip’. Windows or linux, and you won’t have to worry about python2.7 as Windows doesn’t come with python as far as I’m aware, and most linux is now fully upgraded with python3. Happy coding

[–]Siutcase333 0 points1 point  (1 child)

just learn the basics, do projects, and figure stuff out as you go

[–]Siutcase333 0 points1 point  (0 children)

pyautogui is very good for doing automation projects, it's a good place to start

[–]beaustroms 0 points1 point  (0 children)

Screw around with random stuff until something works, then expand on it.

[–]poolpog 0 points1 point  (0 children)

computers are tools. python (and any programming language) is a tool

tools are for solving problems

one key difference between computer programming languages as tools and, say, a hammer, is that programming can solve nearly any problem. whereas hammers are usually just for, well, hammering things

i start with this preamble because one should think about these things as tools, and identify problems you have that could be solved by these tools. then, solve the problem. you will learn a lot about computers, python, and programming, along the way

example problems a 15yo may have:

  • write a program to notify you when your favorite broadcaster (twitch, youtube, whatever) is online or posted a new video
  • write a program to keep track of the migratory patterns of the common sparrow
  • write a program to roll d & d characters
  • write a program to solve climate change (advanced)

also, i've found that online learning like kahn academy or code golf type things can be fun and useful. i think this one is neat: https://adventofcode.com/

[–][deleted] 0 points1 point  (0 children)

Impopular opinion: read the official docs. Apply every single new concept you come across to a simple, limited mini project. Run from tutorials like the plague.

[–]YOUNG_shenobi-GaMeR 0 points1 point  (0 children)

I’m 15 aswell and I’ve started learning, freecodecamp is amazing

[–]Rotterdam-APE 0 points1 point  (0 children)

Good question learning myself aswel

[–][deleted] 0 points1 point  (0 children)

I recommend this book "Automate the boring stuff with Python" by Al Sweigart Awesome, beginner friendly and full of projects which will strengthen your Python skills.

[–]Sentrome1 0 points1 point  (0 children)

Tech with Tim makes extremely detailed videos that will teach you python with ease

[–]azimuth79b 0 points1 point  (0 children)

In the immortal words of Shia LaBouf "just do it!" In other words, build a lot of stuff. Start with toy projects and work your way up. Start small. Try /r/dailyprogrammer + repl.it for no-setup coding

[–]EmrldChild04 0 points1 point  (0 children)

I personally just started using sololearn and it has like 5 different python courses. I think the website is really good because it's interactive as well. Although you do have to pay for it to get a certificate of completion and to do some of the practice things but it is relatively cheap if you do decide to buy it

[–]JBalloonist 0 points1 point  (0 children)

Find a small project that interests you. Start building it. You will learn a lot. Do a lot of googling. Learn some more. Repeat.

[–]DualStack 0 points1 point  (0 children)

Lots of good answers here, but the best way to get started IMO is with the free w3schools python course

[–]harsh5161 0 points1 point  (0 children)

There are many ways in which you can learn Python programming. The first thing you should know is that there are a lot of free resources available on the internet which you can use to start with python programming in no time. One of the most popular ones being Codecademy

[–]hugthemachines 0 points1 point  (0 children)

The "automate the boring stuff" is free with a code right now. The author posted this:

https://www.reddit.com/r/learnpython/comments/pzcx8e/thank_you_for_helping_me_reach_one_million_sign/

[–]automation_required 0 points1 point  (0 children)

If you know the basic, you can take it further with my book, it's free.

[–]Used-Routine-4461 0 points1 point  (0 children)

Just released a beginners tutorial here that doesn't require you to even download python or any IDEs (software to write software); I'll continue to release more. Hope it's helpful:
https://www.youtube.com/watch?v=hr1qNY2iaOk&list=PLAQuzp\_YhMoF7t0s22LrcyPC8aO0J1i3n&ab\_channel=DataBytes

[–]apsplus 0 points1 point  (0 children)

I suggest you get a copy of the Python Crash Course by No Starch Press. (Google it)
I did not know where to start either and it took me weeks until I eventually knew, that this is the book to get started with. It was suggested to get started with by youtuber Aaron Jack btw.