Re: Visualizing Cocoa
Re: Visualizing Cocoa
- Subject: Re: Visualizing Cocoa
- From: David Trevas <email@hidden>
- Date: Sat, 9 Jun 2001 16:38:46 -0500
I agree that more graphic aids should be used in explaining Cocoa,
Objective-C and OO concepts.
I believe that programmers who have slogged through BASIC, Fortran, C
and C++ and other languages to arrive at this stage in history think
that new programmers should endure the same rites of passage they
suffered through.
The idea of sending newbies to learn C first should be a big waste of
time, but the few Objective-C resources out there all assume a knowledge
of C. While the new programmer learns about control structures (if,
while, for) and data types (double, int), they waste time learning about
structures and functions as separate entities. I realize that NSRect's
and NSRange's are structures, but the usage of them can be covered much
more briefly in an Objective-C book.
If someone takes an ObjC guru too literally, they will end up having to
unlearn most of what they just learned. The first program taught
centers around "printf("Hello, world!\n");" First, the Cocoa programmer
should not be using stdio.h functions, in general. Second, beginning C
texts show you how to write code from scratch while a Cocoa programmer
snaps together existing objects, specializes an object that is close to
his desired one or, as a last resort, creates a new subclass of NSObject.
It is very hard to go from learning the procedural (or structured)
programming paradigm to learning the object-oriented one. I believe
that there could be a book written that teaches OO programming with ObjC
and Cocoa to absolute beginners as their first language. It would take
some of the visual aids that behoward proposed to make the concepts
clear enough. I wouldn't be surprised if people starting in ObjC first
end up being better programmers than those of us who spent many years
learning the C, Fortran or old Basic way of programming.