Topic: C++ complexity; too much?


Author: greyham@research.canon.oz.au (Graham Stoney)
Date: Tue, 17 May 1994 00:51:00 GMT
Raw View
In article <0097E62C.AF7A5C88@pomona.claremont.edu>,
Matthew Amster <mamster@pomona.claremont.edu> wrote:
>C++ is a rather unique language in that it is suitable for CS1-level
>instruction and huge, corporate, object-oriented projects.  In any programming
>language except the most simple (interpreted Basic, Logo, etc.), there are
>arcane constructs that are difficult to use and understand, but occasionally
>can be put to great use.  It is one of C++'s strengths, not weaknesses, that it
>is this flexible.

thutt@clark.net (Taylor Hutt) writes:
>If the world's electricians took that logic to heart, you would would have a
>200amp wire in every outlet in your house.  It would be really dangerous
>to use, but think of the things you would be able to do if you had that
>kind of power!

Good analogy actually: using the same material (copper) you can make 200amp,
10amp, 1amp or however heavy or light duty wire you need.  If you've chosen to
make and install 200amp wires where you actually only needed 10amp wires,
that's not the copper's fault.
--
Graham Stoney, Hardware/Software Engineer
Canon Information Systems Research Australia
Ph: + 61 2 805 2909 Fax: + 61 2 805 2929




Author: thutt@clark.net (Taylor Hutt)
Date: 16 May 1994 07:48:49 -0400
Raw View
In article <0097E62C.AF7A5C88@pomona.claremont.edu>,
Matthew Amster <mamster@pomona.claremont.edu> wrote:
>In article <2r1f8n$2oi@news.iastate.edu>, guthrie@miu.edu writes:
>
>>Gosh; is this really a language which in other threads we are discussing
>>teaching for CS1, and to high school students!?!
>>
>>There seems to be something very complex about C++; why?
>>Is there something intrinsically complex about its expressive domain,
>>or has it somehow made things harder than they are (should be)?
>
>C++ is a rather unique language in that it is suitable for CS1-level
>instruction and huge, corporate, object-oriented projects.  In any programming
>language except the most simple (interpreted Basic, Logo, etc.), there are
>arcane constructs that are difficult to use and understand, but occasionally
>can be put to great use.  It is one of C++'s strengths, not weaknesses, that it
>is this flexible.
>

If the world's electricians took that logic to heart, you would would have a
200amp wire in every outlet in your house.  It would be really dangerous
to use, but think of the things you would be able to do if you had that
kind of power!





Author: maxtal@physics.su.OZ.AU (John Max Skaller)
Date: Sat, 14 May 1994 12:06:17 GMT
Raw View
In article <2r1f8n$2oi@news.iastate.edu> guthrie@miu.edu writes:
>
>Gosh; is this really a language which in other threads we are discussing
>teaching for CS1, and to high school students!?!
>
>There seems to be something very complex about C++; why?
>Is there something intrinsically complex about its expressive domain,
>or has it somehow made things harder than they are (should be)?

 One source of complexity in C++ is C. C is old, and not
a modern language, and extending it is difficult. But it is
an important feature of C++ that has made it popular.

 A second source of complexity is the pressure of users
for a Standard. This pressure will prevent simplifying the language
as it could have been simplified had more time been available.

 BOTH these factors are an expression of the fact that
programming is a commercial activity. And there is nothing wrong
with that.

 Finally -- although its not obvious, the basics of
C++ are not that complicated. Nor do most programmers run into
the tricky details every day during their programming activities.

 I agree with Bjarne that C++ is suitable for CS1.
There is no need to teach all the gory details of it. C++ is
designed that way -- its a multi-paradigm tool-kit which
can be used idiomatically for many different purposes.

 Select a subset and a paradigm to teach beginners.
The smarter students will read beyond the lectures  -- so be
prepared to answer hard questions!




--
        JOHN (MAX) SKALLER,         INTERNET:maxtal@suphys.physics.su.oz.au
 Maxtal Pty Ltd,      CSERVE:10236.1703
        6 MacKay St ASHFIELD,     Mem: SA IT/9/22,SC22/WG21
        NSW 2131, AUSTRALIA




Author: guthrie@miu.edu
Date: Fri, 13 May 94 21:04:04 CDT
Raw View
In article<pete@genghis.interbase.borland.com> writes:
> Newsgroups: comp.lang.c++,comp.std.c++
> Subject: Re: "Pointer to array" -> "pointer to const array", Legal?
> Organization: Borland International
> Bob Kline <bkline%occs.nlm.nih.gov> wrote:
> >Robert Mecklenburg (mecklen@oops.cs.utah.edu) wrote:
> >: We have a question on the correct use of const.
> >
> >: The question is: "Is the call of foo correct?"  We believe that it is.
> >: Our logic is as follows:
> >
> >You pose a good question, and I suspect your answer will be correct
> >once the standards committee has added some refinement to the language
> >in the ARM (if it hasn't already).  The ARM, on p. 318, lists
......
>
> This call is illegal. The rule about converting a T* to a const T* is not
> talking about text substitution. It is talking about types. If we treat
> the declaration int **ip as creating a T*, then 'T' must be int*. Which means
> that the trivial conversion applies to (int *), that is, to the pointer. So
> int ** can be converted to int *const *, a pointer to a const pointer to int.
> That is not the same thing as a const int **, which is a pointer to a pointer
> to a const int.
>  -- Pete

Gosh; is this really a language which in other threads we are discussing
teaching for CS1, and to high school students!?!

There seems to be something very complex about C++; why?
Is there something intrinsically complex about its expressive domain,
or has it somehow made things harder than they are (should be)?

You sure never see this type of questions in the SML or scheme groups...!

Gregory Guthrie






Author: mamster@pomona.claremont.edu (Matthew Amster)
Date: Sat, 14 May 1994 04:08:28 GMT
Raw View
In article <2r1f8n$2oi@news.iastate.edu>, guthrie@miu.edu writes:

>Gosh; is this really a language which in other threads we are discussing
>teaching for CS1, and to high school students!?!
>
>There seems to be something very complex about C++; why?
>Is there something intrinsically complex about its expressive domain,
>or has it somehow made things harder than they are (should be)?

C++ is a rather unique language in that it is suitable for CS1-level
instruction and huge, corporate, object-oriented projects.  In any programming
language except the most simple (interpreted Basic, Logo, etc.), there are
arcane constructs that are difficult to use and understand, but occasionally
can be put to great use.  It is one of C++'s strengths, not weaknesses, that it
is this flexible.


-----------------------------------------------------------------------------
Matthew Amster           Pomona College          mamster@pomona.claremont.edu