mkl0815 wrote:
The listings are pictures, so you have to hack it into your editor instead of copy the content and prevent type mistakes.
I'll simply state for small enough examples (for assorted definitions of small), I think typing the code in, mistakes and all, is much better for learning than cut and pasting code, or, worse, just downloading the example and "hit build".
It's always good to have fast success, but typing the stuff in makes you fixate and study on each line. You can type it in blindly, you can ponder each line with "what does this do", you can get better experience with the syntax of the code having to worry about delimiters and terminators and other things that are the nature of source code. Also may help you learn the development tool/IDE that you are using, if it's new to you.
You may even start changing it right away. That's one thing I like to do, I like to change all of the variable names and what not as I type stuff in. It helps reveal assumptions perhaps not expressed well in the code (like naming conventions, etc.). If it doesn't work, no big deal, I can always incrementally convert my hacked code towards the example until it does. Folks are much less likely to work on that when they just cut and paste code in.