Newsgroups: comp.edu,comp.lang.ada,comp.lang.c++,comp.lang.modula2,comp.lang.scheme
Path: cantaloupe.srv.cs.cmu.edu!rochester!cornellcs!uw-beaver!pattis
From: pattis@cs.washington.edu (Richard Pattis)
Subject: Re: Comparison of languages for CS1 and CS2
Sender: news@beaver.cs.washington.edu (who else)
Organization: Computer Science & Engineering, U. of Washington, Seattle
Message-ID: <DBL5r8.BnB@beaver.cs.washington.edu>
References: <3tsp99$233@felix.seas.gwu.edu> <1995Jul11.202739.11299@merlin.hgc.edu> <19950711T232509Z@naggum.no>
X-Nntp-Posting-Host: june.cs.washington.edu
Date: Wed, 12 Jul 1995 04:28:20 GMT
Lines: 69
Xref: glinda.oz.cs.cmu.edu comp.edu:13194 comp.lang.ada:32485 comp.lang.c++:137946 comp.lang.modula2:11989 comp.lang.scheme:13115

Last year UW switched its introductory sequence from Ada to C/C++ (in CS1/CS2).
Here are some comments taken from a bit of a distance - I don't work at UW
any more; I now work at home in what I call my Ivory Basement.

The switch was made primarily because many upper-level courses use C/C++
artifacts. This includes courses in compilers, graphics, and operating
systems. None of these course serve as a prerequisites for any of the others,
and each was trying to teach C/C++ in the first week of the quarter. The
result was deemed to be repeated wasted time, reduced coverage of the core
material, and little mastery of C++ by the students.

An attempt was made to require students to learn/use C++ in our data structures
course (between CS2 and the upper-level courses; previously students could use
any language they wanted, and most continued to use Ada). But the result of
trying this approach was a big decrease in the amount of material covering data
structures, which was squeezed out by all the C++ material.

So, it was decided that we either needed to teach a course specifically in C++
or to change the introductory sequence to C/C++. We didn't believe we could
require students to learn C/C++ by themselves, nor could they adequately learn
it in our "survey of programming languages course"and we didn't want to
displace any other course to make room for a new one (e.g., AI, Software
Engineering, data bases etc.) So we decided to teach C/C++ in CS1/CS2. Eric
Roberts has given a similar rational for Stanford's switch from Pascal to C
(published in his C book, and the 1993 SIGCSE proceedings as a paper).

The results of making the switch were mixed. At one level, the students learn
less sophisticated language structures. In Ada we taught/used exceptions and
generics heavily in CS2; in C++ these features are not covered (and inheritance
is covered only briefly at the end of CS2, but more in our data structures
course). This might be the result of an immature curriculum (we had been
teaching Ada for 6 years), so it could get better. On the other hand, the
students are extremely excited about learning what they perceived to be "real"
languages. I gave a very strong pro-Ada pitch but I could not get through to
many students - possibly their age and UW's proximity to Microsoft were part
of the problem. But, I'd have to say that student enthusiasm should not be 
lightly discounted (in an optimal world, this should not be an issue, but I
live on planet Earth in the late 20th century).

Also, many more students bought/used C++ compilers for their home machines,
which helped in their learning (both motivation and acquiring skills). Again,
I pitched Meridian Ada strongly, and I probably sold (with our site-license
agreement) hundreds at $60.  But that software never came close to looking as
"sexy" or being used as much as Visual/Borland/Symantec/Metrowerks C++ systems
the student use now. These are all available to my students at about the same
price as the Meridian product. All are much more mature products; all come
packaged very professionally (compared to Meridian). I know that Intermetrics
is aiming at this market, but they are still at least 6 months from shipping,
and their resources cannot match the individual efforts of these C++ vendors
(who are all spurred by competing in a marketplace with other vendors; look
what happened to Symantec now that Metrowerks is in the market).

How well these students do in our upper-level courses, and how it affects
these courses is yet to be measured, since students are only now starting to
enroll in these courses.

So, my bottom line is that the "right" choice of language for CS1/CS2 is not
obvious, nor is the criteria for selecting one. The ideal language, on
pedagogical grounds, may not necessarily be the right one on many other
grounds.  And all this from a school that has fewer contraints than many (but
more than some) on how such changes are made. In fact, UW changed to Modula-2
when I arrived in 1985. and again to Ada in 1989. Maybe their problem is that
they are too trendy :)

-- 
  Richard E. Pattis                  "When debugging, a novice programmer
  Looking for a Job		      inserts corrective code; an
			              experienced programmer removes
			              defective code." 
