From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,f3bebae566a54cab X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!news3.google.com!feeder1.cambriumusenet.nl!feed.tweaknews.nl!193.141.40.65.MISMATCH!npeer.de.kpn-eurorings.net!npeer-ng0.de.kpn-eurorings.net!newsfeed.arcor.de!newsspool3.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Mon, 20 Jun 2011 16:40:36 +0200 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.17) Gecko/20110414 Thunderbird/3.1.10 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Some exciting new trends in concurrency and software design References: <8a5765ba-622a-42cd-9886-28ed7cfed31e@s17g2000yqs.googlegroups.com> In-Reply-To: <8a5765ba-622a-42cd-9886-28ed7cfed31e@s17g2000yqs.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <4dff5be5$0$6565$9b4e6d93@newsspool3.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 20 Jun 2011 16:40:37 CEST NNTP-Posting-Host: 559c8a9e.newsspool3.arcor-online.net X-Trace: DXC=HQQW8WI6`SJlU`@c^jLCbJMcF=Q^Z^V3H4Fo<]lROoRA8kFJLh>_cHTX3jMJX6mKg6dc8K X-Complaints-To: usenet-abuse@arcor.de Xref: g2news1.google.com comp.lang.ada:19961 Date: 2011-06-20T16:40:37+02:00 List-Id: On 20.06.11 12:49, jonathan wrote: > We have for decades struggled with using > object-oriented languages, such as Java > or C++, to explain these simple ideas, > and have consistently failed. And I > can tell those of you who are not plugged > into academics at the moment, many of > my colleagues world-wide are in the > same situation, and are desperate to > find a way out. > > Professor Harper favors functional languages, SML in particular, > but at least he's on the right track;-) Not that it matters most, or is most important to the subject of understanding modularity and parallelism, but I must mention that there remain a few major blind spots in FP circles, IMHO. It won't help as is. "There is nothing more dreary than the corporate bureaucracy of OOP, and few things more lovely than the mathematical elegance of FP." Yes, I'd agree that O-O bureaucracy and spaghetti code can be correlated. Why, however, do we not seem to see bureaucracy in ML source text? 0. There is less ML text. Different problem domains, too. Perhaps suggesting a different kind of program right from the start. 1. Actually, they use imperative style or suitable contortions in functional programming when efficiency is required. I remember looking at the chapter on Fusions in Bird's FP in Haskell book. The chapter's subject is messy, the approach produces text similar to the lengthier noodles in Wirth's algorithms book, conflating things for efficiency reasons. Where is the mathematical elegance in that? 2. FP *hides* the effective work's complexity behind a mathematical facade: you write down a nice formula after days of thinking, shouting, explaining, and getting it right. Then, you do *not* document your "thought process" in source text. Instead, you just "sign" days of work with a few nice lines of code. That's quite typical of FP, I think, but just less feasible in "imperative" languages. We can stare at the short FP algorithm in awe of its "mathematical elegance" and start wondering what the heck it is doing behind the scenes. Yes, doing, since doing is what matters, even when we just want to understand an algorithm. At least if Knuth is to be trusted when he suggests that we should follow the steps that algorithms take when we want to understand. A possible opponent to dropping O-O from the early curriculum, Bertrand Meyer, insists that in his approach to O-O (teaching) an object is a module, period. Unlike C++, say. He does show a way out, in a big new book, the Inverted Curriculum IIRC. Eiffel is much "cleaner" than hybrid languages C++ or OCaml or Java. Why not try a clean O-O approach (or just forget implementation inheritance and so on) first before banning O-O programming altogether because with they hybrid languages the author's We failed explaining simple ideas? Incidentally, regarding mathematical elegance, why and when do students still run away from CS? As soon as they are overwhelmed with formality, including inscrutable mathematical elegance. Is it because they aren't bright, or is it rather because they cannot get good explanations? Because their teachers simply presume "obvious" math skills and cannot and do not know what it is like to not have grown up with all prerequisite mathematics. All day. If mathematicians say, for example, that abstract algebra is more difficult than computing with whole numbers, then they have not done their homework before arriving at this verdict. (Algebra having been developed from number theory TTBOMK, should hint at possible reasons.) When a fan of ML (Harper), who, I think, has written an exceptionally good introduction to ML, says that ML works better than O-O when teaching; when, OTOH, a fan of O-O (Meyer), who has written an extraordinary book about O-O (in Eiffel), says that the O-O curriculum works really well at ETHZ, what is a tax payer to make of this? Wouldn't a distant observer immediately want the teachers to swap programming languages and to try the opponent's language in a controlled experiment?