Robert Klemme
2/23/2006 4:28:00 PM
James H. wrote:
> But more importantly, *should* Ruby be a first language taught,
> period? I tend to think no.
That's precisely the point where we disagree. :-)
> C allows you to have a base understanding of all the technical aspects
> of programming, like memory management, procedural thought, and the
> basics of writing methods.
It won't teach you anything about methods because there are none in C. :-)
> These are generally good skills to have,
> and you'll find that you use them everywhere. C is a lot like latin,
> insofar that it's not changing much, and is used to communicate ideas.
I use UML to communicate ideas - or Ruby - but certainly not C. I don't
think it's suited for this at all. There's too much overhead.
> I also think it's a little more "native" to initial human
> understanding about programming. People tend to think of it as a
> linear, or semi-cyclical set of instructions. In that regard, I
> think C is a good way to enter the scene.
Even if you want to start with a strictly procedural language I'd strongly
favour Pascal over C exactly because those detailed technical aspects are
*not* present there. Getting memory allocation and pointer handling right
is difficult for a novice and prevents early successes. IMHO it's far
more important to grasp abstract concepts that are common to many
programming languages (like abstraction, modularization, data structures)
than to know how to not shoot yourself in the foot when doing *ptr++.
> The thought process overhead in object oriented programming is quite
> extensive. It takes a long time to really get in the mode. If you
> learn somethings about C, and get a basic grasp before moving on to
> Ruby, you'll understand and have a better appreciation for some of the
> "magic" going on behind the scenes, as well as opening other avenues
> for your programming career. Doubly, it takes a long time to learn
> how to think in objects -- something I admit, myself, to just be
> getting the hang of. When you start reading about design patterns,
> you realize the complexity, and beauty that OOP allows you.
Although I agree with your last paragraph (that OO is more difficult to
grasp than the procedural paradigma) I strongly disagree with what you
state in the first paragraph. If you like to, you can use Ruby
procedurally most of the time.
Kind regards
robert