Self-Study Philosophy and Getting the Goods

OK, so basically there are two ways to learn to program. Three if you count taking a class.

Taking a class is great. There's someone who knows something to ask questions of, a peer group to turn to for help, and structure so you really keep at it. You'll have to put up with the pace of the class, which is never exactly your pace, and the examples and assignments, which aren't exactly what you're most interested in; but you can be pretty sure you'll get a thorough run through the important elements of the subject.

One non-class way is to get a book and read it all the way through and then start to do what you want, looking back at the book whenever you're not sure what to do. The best Amiga programmer I ever met said that's how he approached it. Part of the same way is to key in all the examples in the book, following along step by step. That works great if you can stay awake until you've finished reading. I usually can't.

The other way, which I often use (and I mean that every time I learn a new computer language or programming environment I do this) is to find a program that does something interesting and start tweaking it. I make a little change to the code and see if it changes the program's behavior the way I expected, and then another change, and pretty soon it doesn't look much like the original program. The trouble with that approach is that I never get to the end of the book, and there are lots of features of the language or the environment that I don't get to learn very well, but I get some results long before the people who are trying to read the whole book.

I urge you to use both approaches. Don't just read one book or web site; you'll learn more from seeing several different views of the same problem. I don't have all the answers, and probably I don't even have very many, but I have fun finding out the ones I do find.

Let's assume that by this time you have installed the Developer Tools that Apple supplies with Mac OS X. If not, go to Apple's web site (duh! and click on "developer".

Halfway down the middle column of the developer page you'll see "tools". Give it a try. You may have to sign up as a member of the developer site, but I seem to remember that's free (you'll just get an email from Apple every week with developer news). Get the tools and install them. OK.

Now even if you already had the tools installed, go to the developer page. Just under "tools" you'll see "sample code". Click on it. In the page that comes up, in the left-hand column, click on "Cocoa"(I know I could give you a direct link to that page, but I'm trying to teach you how to do this stuff on your own). There's a ton of example code here. You can download any of these, build the programs, play with them, read the code to learn how to do things, or change the programs to suit your own interests. Many of the examples are specialized. They're exactly what you need to solve some tricky Mac programming task, but aren't much interesting otherwise. The one I recommend just for playing with is Son of Silly Balls. You can download it from the Apple developer site. Since I didn't see any copyright notices telling me not to, and in fact I did see a message at the bottom of its readme file saying "Share and enjoy", I've copied it to this site. Download it right here.

Home       Back       Next