written by owen on 2005-Apr-13.
Computer programming in general is about solving problems and avoiding errors. It is defined as;
creating a sequence of instructions to enable the computer to do something
Computer programs are written by programmers. Whom spend most of their time trying to figure out the best way to solve a problem using the tools or languages which they know. Knowing a language is crucial because a programmer will never be able to solve a program problem unless he or she knows how to solve the problem. So the next question is how does a programmer learn to solve problems?
Problems usually have many solutions
The more problems you have solved in the past the easier it is to solve future problems. In effect the more expirience you have solving problems and writing code - the better programmer you become over time. Most problems are solved in a number of ways
- Trail and error - spend an amount of time trying different bits of code until you come up with an answer.
- Research - finding somebody or some information on how to solve a problem.
- Experience - you did something similar before so this problem can be solved basically the same way.
Step 1: Getting started
You need to find a nice little language in which to write your code. Finding a nice language is important. You should be able to setup and run you program without any help from anybody. Some people may need programming books or tutorials. Make sure you have the help files that come with the language so that you can look up the meanings of errors you will encounter. Nice languages have nice help files that you can read and understand. Some errors are not in the help and you have to ask a human to explain it. Seek professional help.
Step 2: Find a problem to solve
Once you up and running with one or two simple programs you learned in class, tv or got from somebody, you should find yourself a problem to solve. It is important for you find a problem of your own choosing so that you will be committed to solving it. It could be a calculator, game or operating system it does not matter - everything starts somewhere.
Step 3: write the program
Start writing your program. It may take you 2 days, 2 months or 2 years to solve the problem depending on how big the problem is or how quickly you learn. In some cases problems are never solved and are left waiting in a file somewhere. It is important not to rush through when writing your program - keep a steady pace. If a problem come up often times it is best to just shutdown you machine and go to sleep.
Step 4: Re-write the program
A program usually never comes to a state of completion. You will realise that the closer you come to completing it the more new solutions appear. So you either stop writing the program at some point or you keep messing with it indefinitely.
Step 5: Find another problem
After you reach a point in your first program and your show it off to your friends, you will need to find a new project to work on. The more problems you solve the better you will become. Note that sometimes a problem cannot be completely solved.