Why programming with python 3 so hard?
I'm finally taking a scripting class, and I realize programming is not for me. it's funny how I was passionate to learn about it, now I realize that it is really hard.
I really want to understand it, but using the required website for my class called "ZyBooks", It's not helping me understand it.
#classes #college #school #general #python3 #python #programming #coding #scripting #IT #informationTechnology #major #career #professor #technology
11 answers
Dhairya’s Answer
Thanks for your post. Learning to program for the first time can be challenging. Its totally normal to be frustrated and find yourself stuck when trying to write code.
Luckily there's many resources online. If you find reading a textbook isn't helpful, I'd suggest looking at youtube and other online resources that might offer better explanations. I'll list a few sites below that might be helpful.
The trick to learning python and any coding language is to start simple. For solving a problem, I like to outline out logic in comments and then code each step in the outline. Write a line, run it and see what outputs. Then write another line. It's slow but the more you write code, run it, and check the output, the better your understanding becomes. Even 10 year later, I'll do the same thing when trying to figure out a tricky problem or understand external code.
If you're running into logic errors, comment out your code and try debugging line by line and printing out statements. You can also try google the errors messages and see if others have faced similar issues. If its syntax issues, I suggest writing code in an IDE that has linter which highlights syntax errors and tracks your indentation/ white spacing.
Also you should go to office hours and talk to your professor when you feel stuck. Your professor and TAs are there to help and often having another human looking at your code really helps. Finally, also checkout stackexchange and post your challenges there. You'll find many folks willing to help you with your coding challenges.
I hope you stick with computer science and programming. When you get stuck ask for help, whether its online or your professor and TAs. It really does get easier with practice. Good luck!
Dhairya recommends the following next steps:
Meghana’s Answer
I am very happy to hear that you chose to learn Python 3 and not because someone forced you to do it. Well, that's the first step and a big step. I started to learn python after my graduation. I understand that you might feel it is hard. But it is not impossible to learn. You can do it! Keep your mind open. Don't give up. You have come this far.
It is absolutely fine if you don't understand something in it. Just keep moving forward. I started learning python by reading a book named "How to think like a Computer Scientist". It is like the bible of Python. It was really helpful. After reading every chapter, I used to try it out in my python console. I also used to solve the exercises. I still refer this book if I want to learn some basics. You can give it a try!
I used to solve some challenges in Hacker rank. I attended a course on Python in Data camp. It was very helpful. Apart from these, I used to refer Geeks for Geeks for many python based questions asked in interviews.
Also, from my experience I would like to share with you that programming is not something you learn and you leave it. We have to keep practicing everyday or at least be in touch with it, else we tend to forget about it very soon. Python is like an Ocean. It is used in lot of domains. Try to explore them. You might not like data structures in python. Try some other one like data science in python. You might like it. So, don't give up.
"Try and Try till you Succeed!"
Meghana recommends the following next steps:
Victoria’s Answer
My father started a software company so he expected all of his kids to be great coders out of the 3 of us none were able to really understand it. I definitely understand the struggle of wanting to understand it and thinking that coding was just not meant for me. It can be really hard but on the other hand my husband recently taught himself how to code in python from watching a 5 hour classroom style YouTube video. He studied it in sections and just a few months later was hired as a junior developer with no college degree.
Coding isn't for everyone so you shouldn't feel disheartened if you choose not to pursue it but try looking outside what your teacher is offering for resources and you might find something that helps you learn it. Good Luck!
Nikhil’s Answer
First of all , you have picked a great language to learn. Python is used extensively in all software domains. So learning Python gives you the opportunity to work in various software fields. I come from a computer hardware background and trust me we also use Python. So don't give up learning python.
The way I would learn any language is by writing code. Fire-up an online Python simulator and start coding .
Write a line -> compile , write a line -> compile . This way you know exactly where the issue is and debugging becomes easy.
Next start simple. Start with the basics . Once you have mastered the basics, its much easier to move on to the convoluted concepts.
Also don't by-heart the syntax. In the industry people still google the syntax and code. I do it too. So don't focus on the syntax, learn what the syntax means.
Try this one hour a day. See how it is goes . If you can't grasp the language write back on the group and we can figure it out from there.
Happy Learning.
Rodrigo’s Answer
First of all not feel bad at it, coding is not easy, same occurs to me, I tried some courses on the internet , as many here have mentioned, but maybe you can try starting with visual basic, they are more basic stuff and you may first understad the principles, (if, for, while), the you can jump to python which is a great lenguage , check the link below, and maybe you can start develop some things there, what it works for me was working on some excel macros, and learning to do that, because it uses visual basic, if you understadn that maybe will help a lot understading python and the logic of it
Rodrigo recommends the following next steps:
Joy’s Answer
If you are looking for python language i suggest "hackerrank" and "GeeksforGeeks" as go to sites where you can find lot of information related to each topic. Take incremental steps but practice daily.
Kris’s Answer
David’s Answer
Stick to it. Take small steps. If it's a career prospect for you - it will start making sense and be less frustrating the further you go.
In particular, I recommend a site like HackerRank -- the lessons are "nibble sized" -- you can run through 3 or 4 lessons in an hour,
and know what you just learned.
In particular, once you have done one of the exercises - READ some of the other answers posted for the exercise. It's fresh in your mind how you solved the problem - so seeing how other folk approached it can add more tools to your toolbox.
Hristo’s Answer
Much like math, any scientific or engineering discipline, a new language or even learning to walk at some point of time, unfamiliar concepts, topics and skills can seem hard even impossible to master, that isn't the case however with enough exposure, practice and perseverance you can become proficient in just about anything given enough time.
You don't have to become the best python programmer or even go further than gaining some fundamentals on the subject but if you are curious and passionate about the topic do not let the fact that it can be hard and even frustrating at time discourage you from learning. The best reward come the end of hard roads and that is very true for learning as well. Even if you never program after this again, gaining that knowledge and more so seeing that you have the ability to push through tough concepts and come out on the other side will serve you greatly in just about anything you chose to do after.
As to more specific advice on the topic, looking into some more general programming fundamentals will likely clear up a lot of your questions specific to your class. As is with anything else all concepts are built on other less complex concepts and sometime when we haven't first encountered the base concept the higher concept can seem completely cryptic. Think if you had to solve an algebra problem but you had never encountered the concepts of arithmetic first.
Going through these more general learning materials can greatly help by introducing you the basic concepts around programming that you need to internalize before diving into specifics languages and faster paced courses:
https://www.youtube.com/playlist?list=PLzZR2BJ8ICYu7uPFuvkjcIxkPE-1SEkNo - Introduction to programming
https://www.youtube.com/playlist?list=PL8dPuuaLjXtNlUrzyH5r6jN9ulIgZBpdo - Crash Course series on Computer Science (does an excellent job of giving a good overview of fundamentals without getting too deep in the subject)
https://www.khanacademy.org/computing/computer-programming
John’s Answer
In the beginning every language may seem difficult to learn, but you need to just keep going, once you have a good base in any language the rest are fairly easy, so if you follow functional programming the first thing is to have a good base of how functional programming works, now for python3 you will need a simple OOP base which will make it easy for you to learn, there are things like parallelism and concurrency that you may want to learn after some time, but as long as you write simple things at the beginning you will be writing simple functions and importing modules as in any other language, please adopt an standard like PEP8 or something and learn a bit from `Don't repeat yourself` and `Single responsibility concept` that way you will learn the good way, otherwise you will end up with a mess of modules with thousands of lines of code.
My recommendation is learning the basics from any tutorial, writing a hello world app in python3 and then keep doing what you are interested in, just have an objective application, the other option is to get a python job and be paid for learning it, that is enough motivation.