[comp.lang.c] Languages and learning

nevin1@ihlpf.ATT.COM (00704A-Liber) (01/22/88)

[followups to comp.lang.misc]


In article <11348@brl-adm.ARPA> dsill@NSWC-OAS.arpa (Dave Sill) writes:
>In article <4186@eagle.ukc.ac.uk> "H.A.Shaw" <has@eagle.ukc.ac.UK> writes:
>>I wholeheartedly agree, and hope I write better C
>>programs now for three years of BASIC/PASCAL/FORTRAN/FORTH first.
>>They did teach [C] to third year Computer Scientists sometimes.
>
>This is much too late.  Computer education should proceed from a
>hardware overview to machine language to assembler language to low-
>level compiled languages on up to high-level compiled languages.
>Teaching BASIC/Pascal/FORTRAN/Forth/etc first is like teaching algebra
>before arithmetic.

I don't know if this is the best way to learn computer programming.  Without
any previous experience, I think it would be extremely difficult to impossible
to debug a machine language program (although I do, I know that not everybody
in the world grasps logic easily).  In the beginning, it is very rewarding to
get a program to do something without too much effort; in assembler, even
printing out your name requires a non-trivial amount of work.  Most people
would probably just give up on computers.

>BASIC is a bad joke.  The bad habits that it imparts on students are
>particularly hard to unlearn (first impressions are lasting
>impressions).  It oversimplifies the hardware-software interface to
>the point where it seems, to the student, to be performing magic.  C
>on the other hand, is more transparent.  It allows the student to see
>the gears turning.

Non-structured BASIC (recently, I have seen some versions with Pascal-like
constructs in them) do bring on some very bad habits, I'll admit.  But most
HLLs oversimplify the hardware-software interface.  In my job, I very rarely
have to deal with hardware directly; I usually use standard system calls so
that to my program, all the hardware looks the same (this is one of the
purposes of an operating system).  I don't know what the best language to start
with is, but I don't think the bottom-up approach (i.e., starting with machine
language) has enough benefits to outweigh the problems.  Maybe starting with
Lisp (a language which can be described very simply) and teaching theory is the
way to go (I think this is MIT's approach); I really don't know.  None of the
current languages seem very good for an introduction (sorry, Mr. Kernighan and
Mr. Ritchie :-)).
-- 
 _ __			NEVIN J. LIBER	..!ihnp4!ihlpf!nevin1	(312) 510-6194
' )  )				"The secret compartment of my ring I fill
 /  / _ , __o  ____		 with an Underdog super-energy pill."
/  (_</_\/ <__/ / <_	These are solely MY opinions, not AT&T's, blah blah blah