Jump to content
  • Advertisement
Sign in to follow this  
truthS

.

This topic is 4847 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
I find that other people's code is a very good resource for learning from, especially when it uses some function or method that you've never used before, as you get to see an example of how it can be used. This is especially so if the code is accompanied by a good explanation not only of the code, but also of the theory behind what you're actually doing.

However, just reading the other person's code isn't the best way to learn in my opinion; I feel that to get a good grip on what's really happening it's best to play around with the code a bit. Read through it until you think you understand, and then pick something to change. Try to predict what will happen if you make the change, then actually try it and see what happens. If you have a good fiddle with altering the code and seeing what different things happen (and finding out why they happen if you don't understand) then you should develop an excellent understanding of the subject matter.


That being said, it's also very good practice to try applying whatever it is that you've learnt in a program of your own, and sometimes just messing around with a reference guide until you can get your idea working is an excellent way to not only learn, but to actually get something potentially useful done.


Just as a side note, you don't have to hit enter at the end of each line, the forum software will automatically wrap the text for you, which is a bit easier to read. [smile]

Share this post


Link to post
Share on other sites
Lego is a pretty good analogy for programming actually (we have them in Australia too, I think they're pretty global [wink]). You can read the instructions that come with your newly purchased lego model as much as you want, and it'll probably be easier than working purely from a picture of what you're trying to build, but until you actually try building it yourself you won't have a full understanding of how it all fits together.

Just keep in mind, hardly anyone actually memorises all of the functions and thier parameters, etc. which is something a lot of beginners try to do until they realise otherwise. Through experience and practice you do start to actually learn a lot of them from memory, but to be a good programmer it's more important to be able to find the information you need quickly and efficiently. Just a little something extra to keep in mind.

Share this post


Link to post
Share on other sites
Lego originates from Denmark (That is Scandinavia, Northern Europe.. for those geographically challenged :) )

And yes, I'd say every l a n g u a g e we use are like Legos, no matter if it's C++, English or Danish. When you build up a sentence (or a whole book) you use the rules of the language to build up the whole thing (alphabet, words (meaning) grammar..).
Only in the beginning do you have to constantly look things up in the dictionary, or even use one of those "phrase"-books for tourists ("Where can I find a restroom?"), which is very similiar to looking at someone else's code to see "How do I search for a x in a y with a z..".
When you do know "how to program" the problem is always in the big picture. How to solve a big problem in an appropriate way. When finding a solution to this problem, it often has very little to do with the actual code.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!