Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cwjcc!gatech!hubcap!hutch%citron.cs.clemson.edu From: hutch%citron.cs.clemson.edu@hubcap.clemson.edu (David Hutchens) Newsgroups: comp.lang.misc Subject: Re: Learning Ada Message-ID: <6356@hubcap.clemson.edu> Date: 31 Aug 89 13:50:06 GMT References: <6354@hubcap.clemson.edu> Sender: news@hubcap.clemson.edu Reply-To: hutch%citron.cs.clemson.edu@hubcap.clemson.edu Lines: 31 From article <6354@hubcap.clemson.edu>, by billwolf%hazel.cs.clemson.edu@hubcap.clemson.edu (William Thomas Wolfe,2847,): > From article <283@castle.ed.ac.uk>, by db@lfcs.ed.ac.uk (Dave Berry): >> >> What about having the compiler complain about something obscure or advanced >> that you won't learn about for ages, just because you made a simple >> mistake in writing your rpogram > > Students should have little trouble with this as they write their > "rpogram", since Ada has very few reserved words. It only becomes > a problem in languages like COBOL, whose reserved words number well > over 200... > Of course there is the classic (from Ada): "Gee I need the cube of X": z := x ** 3; which, of course (:-) generates the message "Ambiguous Expression". The beginning student might be slightly confused by the reason: "The constant 3 is overloaded (as both integer and short integer) and there are 2 distinct ** operators, so the compiler doesn't know which to pick!" If there are enough of these, the number of reserved words doesn't matter as it plays no role in the confusion. Note: I'm not sure if there are enough in Ada or not, but reports from people who have taught it as a first language suggests it works reasonably well. Besides there are weird things like this in all languages. David Hutchens hutch@hubcap.clemson.edu