3.1233 programming languages (188)

Willard McCarty (MCCARTY@vm.epas.utoronto.ca)
Thu, 29 Mar 90 22:07:59 EST

Humanist Discussion Group, Vol. 3, No. 1233. Thursday, 29 Mar 1990.


(1) Date: Wed, 28 Mar 90 21:15 EST (19 lines)
From: <KANSKI@CWRU>
Subject: scheme

(2) Date: Thu, 29 Mar 90 01:13:54 -0800 (22 lines)
From: edwards%cogsci.Berkeley.EDU@lilac.berkeley.edu (Jane Edwards)
Subject: Turbo PASCAL and string manipulation

(3) Date: Thu, 29 Mar 90 08:28 CST (101 lines)
From: John Baima <D024JKB@UTARLG>
Subject: Learning to program

(4) Date: Thu, 29 Mar 90 15:02:52 EST (18 lines)
From: Stephen Clausing <SCLAUS@YALEVM>
Subject: programming languages

(1) --------------------------------------------------------------------
Date: Wed, 28 Mar 90 21:15 EST
From: <KANSKI@CWRU>
Subject: scheme

[The following has been forwarded from a non-Humanist. --W.M.]

Tell them SCHEME is the only way to go. The language you use (including
English) structures the way you think about and deal with concepts. Some
languages are better for some concepts (hence lambda calculus in math).
Scheme (and the Red MIT book) are (teach) a better way of thinking about
problems. Once you've thought about things in a scheme manner, you'll be
changed (for the better) for life.

cjs

p.s. forward this note to your humanist friends.
(2) --------------------------------------------------------------35----
Date: Thu, 29 Mar 90 01:13:54 -0800
From: edwards%cogsci.Berkeley.EDU@lilac.berkeley.edu (Jane Edwards)
Subject: Turbo PASCAL and string manipulation

I was puzzled by two aspects of Richard Goerwitz' posting concerning
PASCAL's string-handling facilities: (1) that PASCAL presumably lacks
extensive string handling facilities EXCEPT when (2) they are added
locally in which case they are non-portable:
> Both Pascal
> and C suffer from a lack of extensive string processing facilities like
> what Icon and Snobol have. Vendors often add these facilities (which are
> never as good as the ones in Snobol or Icon), but these are, by definition,
> non-portable. Unless you want to get socked into a particular vendor, and
> a specific machine architecture or operating system, I'd think it would
> be better to do things involving language, symbols, etc. in Icon.

In contrast, I was very favorably impressed by Turbo Pascal's string handling
capabilities, which certainly seem extensive enough, and Turbo Pascal is
certainly very portable. I must assume that Richard was thinking of a
different or less portable version of Pascal that Turbo Pascal.

-Jane
(3) --------------------------------------------------------------107---
Date: Thu, 29 Mar 90 08:28 CST
From: John Baima <D024JKB@UTARLG>
Subject: Learning to program


I have taught a beginning programming class at a college and
I really think that BASIC as the primary language of an
introductory class is appalling. Not because there are not
useful languages that call themselves BASIC (BASIC probably
being the least well defined language). I think that the
various languages should be evaluated on their ability to
teach the crucial concepts of programming and this is a
wholly different set of concerns than what makes a good
production environment for either a competent hobbyist or
professional.

My two language choices for an introductory class in
programming for HUMANISTS would be Pascal or Smalltalk.
Pascal was designed as a teaching tool and I do not think it
has been surpassed as a tool for teaching traditional
procedural languages. It is clear and simple yet has
important features that are not in languages such as BASIC or
C (e.g., enumerated ordinal types). C would be about my last
choice for learning programming. The very attributes of C
that make it a favorite of professional systems programmers
are the very things that condemn it as an introductory
course, in my opinion.

BASIC, I think, is also a rather poor choice for an
introductory class in the art of programming. One of the
magazines mentioned in the HUMANIST message supporting BASIC
once had a contest to see who could write the most useful 4
line program in BASIC. That was supposed to demonstrate to
the world that BASIC was a superior language. I thought the
contest proved the opposite. BASIC also lacks pointers which
is an important feature in many languages.

While ICON has many powerful commands, and one of my
colleagues here likes it a lot, I think that it is very
unsuitable for *learning* how to program. ICON does not have
operator overloading for even simple operators like "+" which
means that every combination of every data type needs a
different operator to add two things together. The last time
I looked, Icon had almost 30 assignment operators. What a
mess for the beginner!

I think that Smalltalk should also be given serious
consideration because in programming, the 90's will be the
decade of the Object. I firmly believe in an "Object
Oriented" future for programming and Smalltalk is a
brilliant, pure object oriented language. By "pure" I mean
that *everything* in Smalltalk is a first class object. While
experienced programmers usually have a difficult time
learning Smalltalk because it is totally different than
traditional languages I have been told that beginners to not
experience the same shock. I would chose Digitalk's
Smalltalk/V over ParcPlace's Smalltalk-80, although I
consider Smalltalk-80 to be clearly superior as a production
language for professionals. Smalltalk/V is inexpensive and
is available on both the Mac and PC's. Many University's have
a University license for either/both Smalltalks.

If one learns the ideas of programing well, learning
languages such as Icon or even BASIC is trivial. If someone
learns just how to solve certain text processing problems and
does not understand programming well, their ability to extend
the scope of their programming will be limited. While it is
certainly possible to teach both in a class, I am dismayed at
the thought of innocent students learning to program in
BASIC.

I must also make a comment about something that was posted
yesterday, "If you do contemplate a major programming project
(big program) or a task that requires speed, then you will
need to implement well-structured code and adopt 'C' or even
assembly language." The fallacy is that C produces fast code.
While it is true that many C *implementations* produce fast
code, it is not C that makes it fast. In fact, most C
compilers have implemented a "Pascal" option for subroutine
calling conventions because the Pascal scheme is faster. The
MetaWare Pascal and the TopSpeed Modula-2 are both examples
of excellent compilers that generally produce code that is
better than most C compilers, including Microsoft's.

Nicolas Wirth, one of my heros, has argued that it is
necessary to learn all of a language before one can program
effectively. I agree with that and I think that it is much
easier to learn all of Pascal and come to a good
understanding of programming with Pascal than just about any
other language. Once you understand programming you can of
course use any language that fits your fancy and the job at
hand.

Finally, I do not think that these discussions about
languages is pointless. Rather, I think that they can provide
interesting information about what is being used any why. All
of us who are interested in programming can learn something.
The rest haven't read this far anyway!

John Baima
john@utafll.lonestar.org
(4) --------------------------------------------------------------26----
Date: Thu, 29 Mar 90 15:02:52 EST
From: Stephen Clausing <SCLAUS@YALEVM>
Subject: programming languages

As a German teacher who has also taught Computer Science in a CS
department, I feel I have a right to add to this discussion. I have
learned at various times and to various degrees Basic, Pascal, Snobol4
and Lisp. I have taught and use Pascal. I doubt that there is a single
CS dept. in the country that teaches Basic to its students (Ok, maybe
Dartmouth does, but that's special). Aside from the fact that most
forms of Basic are really too basic to be of value, the language simply
is not a common programming flatform in commercial or scientific
applications. Snobol4 was an ingenious language in many respects, but
it never really caught on. The Icon language sounds like an improvement
(I have never used it), but we are still dealing with a fairly obscure
language. Lisp is well-known for its AI potential (along with Prolog)
but I do not recommend it as a beginning language. By contrast, nearly
all CS students learn Pascal and C. These are both excellent languages,
though I find Pascal more user-friendly. Conclusion: learn Pascal.