I would like to know the best methods for learning to program
A. Read, practice and experiment
My problem is that I understand what I read but I can't apply my knowledge to anything.
A. Start with simple programs first. Your first program can be to print something on the screen. The next program can be a loop to print numbers from 1 to 100. And so on. Don't try to write large programs at the beginning itself.
Should I stick with Python? (is there a better language I should be learning?) Where can I learn programming theory?
A. No problem with sticking to Python. Its a good language for beginners. You can learn theory using good programming books or on the Internet.
I get very hyper when reading my book sometimes, any tips on staying calm and focusing?
A. You may be very exited to develop games and want to do it ASAP. But not able to do so in a small time makes you hyper. Please understand that it may take you several weeks to learn programming. Have patience. If you make haste, you may fail and eventually get frustrated and give up!
Ultimately I feel like I am in a never ending tunnel that leads me no where. It feels like I am just completely unable to pursue anything in the world of programming, yet it is something I want to do very much.
A. Reading the above lines, tells me that you are passionate about programming. I bet that you have the ability to be the best programmer. The problem seems that you are in a hurry to develop your first game! :) Once again, please be patient. If you are not patient, frustration of failure will make you give up and you may never be able to write your own games.
I had written the below article some time back. Read it.
If you are not so good at programming you might have surely asked this question. And if you are a good programmer you might have surely faced this question.
The question I am talking about is, "How can I learn programming?"
This article is an attempt to answer this question. I have written ten points which I think would be helpful for being a programmer. Here they go.
1. Improve your typing speed
Surprising? But this is the most important point. There is no way in which you can convert your thoughts directly into a program. You have to key in your code using a keyboard. If you are really slow at typing, you may get irritated when writing large programs.
Spend at least 30 minutes a day to practice typing. There are several free typing tutors available on the Internet which are worth trying.
2. Get access to a computer
You are not going to be a programmer just by reading programming books. Typing the programs, compiling and executing them is a must.
If you don't have a computer at home, get one. You don't need a brand new Dual Core processor to learn programming. Even an old machine would do for a beginner. If you can't afford that too, at least get access to a computer at your school, college, a library or at your friends place where you can practice programming.
3. Don't just read... Do it!
Don't just keep reading programming books and articles. Mere reading will not help you learn much. Type the programs, compile and execute them. In that way you will be able to remember the things better.
4. Study the code written by other programmers
No matter how intelligent you are, you cannot be the best at everything. You may be writing great programs. But somebody else may write some things better than you.
So even if you think that you have written the best program in the world, its worth checking how others have written the same thing. You can learn a lot from other's programming styles and tricks!
5. Experiment a lot
Don't just stick to whatever the books say or your teachers or friends say. Experiment! Try your own things. Try writing the same program in different ways.
Try whatever strikes your mind. Sometimes things which seem to be foolish will do the job just right! Sometimes your experiments will not give the results you expected, but they may result into something which you thought would never happen! If you get such results, try finding the reason behind them.
6. Be a self learner
Leave behind the habit of being spoon fed. Start learning yourself. There is wide range of content available on the Internet. There are thousands of books in the library waiting to be read. Go, pick couple of them.
If you expect others to teach you everything then programming in not for you. Technology is changing fast. You have to stay updated yourself.
7. Learn from other programmers
This point may seem contradictory to the previous one, but it isn't. I don't mean to say that you should learn programming from other programmers. What I mean to say is learn their programming style. Learn their habits. Try to find out why they are good programmers. Adopt some of their characteristics which you think will help you.
8. Teach someone
Teachers say this often, "You only learn when you teach." Agreed to a large extent.
After you learn something, teach it to someone who wants to learn it. When you teach someone, you will be asked questions. Finding the answers to those questions will grow your knowledge.
9. Think 100 times before blaming the compiler!
I have seen many newbies blaming the complier for errors. They claim their program to be correct and say that the compiler is producing wrong errors. I tell you, in most of the cases (rather in almost every case) it is the programmers fault. My advice is, please think 100 times before you blame the compiler.
10. Be patient and keep practicing
Have patience. You are not going to be a programming expert in a day or two. It takes time to build your knowledge and skills.
Sincerely keep doing your job of practicing, experimenting, learning and teaching. Don't give up!