Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.csd.uwm.edu!cs.utexas.edu!uunet!yale!haveraaen-magne
From: haveraaen-magne@CS.YALE.EDU (Magne Haveraaen)
Newsgroups: comp.lang.misc
Subject: Re: Which language to teach first?
Summary: Pascal & ADTs
Message-ID: <69769@yale-celray.yale.UUCP>
Date: 16 Aug 89 16:31:45 GMT
References: <2584@aplcen.apl.jhu.edu> <6226@hubcap.clemson.edu> <2449@cbnewsc.ATT.COM>
Sender: root@yale.UUCP
Reply-To: haveraaen-magne@CS.YALE.EDU (Magne Haveraaen)
Organization: Yale University Computer Science Dept, New Haven CT  06520-2158
Lines: 41

In article <2449@cbnewsc.ATT.COM> nevin1@ihlpb.ATT.COM (nevin.j.liber) writes:
>In article <6226@hubcap.clemson.edu> billwolf%hazel.cs.clemson.edu@hubcap.clemson.edu writes:
>>    No, actually, students need to be exposed to ADTs early.
>
>I don't know.  I tend to laugh when I get a non-trivial (and usually
>incomplete) spec for a trivial program, which is what most of the
>beginning CS programs tend to have.  It makes ADTs *seem* like useless
>overhead [...]

Having taught intro cs. courses at the University of Bergen (Norway)
for some time I would like to remark that it is virtually impossible to
give a beginning student an assignment that is large enough to show the
usefulness of any good programming method without drowning the students
in work. With smaller examples, however, students who have been hacking
at home, tend to use the "hacker approach" to solve the assignments
quickly, seeing the proper method as "useless overhead".

I still think Pascal is a good introductory language, its major
shortcoming being lack of ADTs and descriptive parameter modes. We have
developed an extension to Pascal, called ADT-Pascal, that adds these
features in a Pascalesc way. So at the end of the first semester, and
during the second semester, we let the students use this language. We
also provide them with some generic ADT modules they may use. The
second semester assignments are so large that students form teams to
solve them. This also shows the need for specifications independent of
implementations, as well as software component reuse.

ADT Pascal blends nicely with Pascal, so a 20 page booklet is enough to
supplement a standard Pascal textbook on these issues. We were
originally thinking of using Modula-2, but dropped it since Modula-2
lacks generic (or polymorphic) modules, and all text books seemed to
describe horrendous methods for adding it to ones code. Ada was out of
the question as well:  Compilers were too expensive (both to buy and in
terms of hardware requirements), and there were no good introductory
text books using Ada. I also feel that Ada is a bit to complex for this
purpose, although useful later on.


Magne Haveraaen		(haveraaen-magne@cs.yale.edu)
Disclaimer: These views have nothing to do with Yale, I haven't even
taught there.