From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id JAA18117; Tue, 29 Apr 2003 09:57:56 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id JAA17973 for ; Tue, 29 Apr 2003 09:57:55 +0200 (MET DST) Received: from teutates.kfunigraz.ac.at (TEUTATES.kfunigraz.ac.at [143.50.129.26]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id h3T7vsH24109 for ; Tue, 29 Apr 2003 09:57:54 +0200 (MET DST) Received: from localhost (localhost.localdomain [127.0.0.1]) by teutates.kfunigraz.ac.at (Postfix) with ESMTP id D6D033D2225; Tue, 29 Apr 2003 09:57:52 +0200 (CEST) Received: from teutates.kfunigraz.ac.at ([127.0.0.1]) by localhost (teutates.kfunigraz.ac.at [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 30168-03; Tue, 29 Apr 2003 09:57:45 +0200 (CEST) Received: from stud.uni-graz.at (IGAM08AV.kfunigraz.ac.at [143.50.39.35]) by teutates.kfunigraz.ac.at (Postfix) with ESMTP id 4AC013D2222; Tue, 29 Apr 2003 09:57:45 +0200 (CEST) Message-ID: <3EAE1FA8.6060609@stud.uni-graz.at> Date: Tue, 29 Apr 2003 08:46:00 +0200 From: Siegfried Gonzi User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.8) Gecko/20020204 X-Accept-Language: en-us MIME-Version: 1.0 To: brogoff@speakeasy.net Cc: "caml-list@inria.fr" Subject: Re: [Caml-list] Easy solution in OCaml? References: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at stud.uni-graz.at X-Spam: no; 0.00; siegfried:01 gonzi:01 stud:99 caml-list:01 brogoff:01 measly:99 haskell:01 get's:01 char:01 ocaml:01 speakeasy:01 lazy:02 string:03 wrote:03 markus:04 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk brogoff@speakeasy.net wrote: > > >Perhaps the question could go back to the Clean designers too. Why are they >worried about two measly keywords? My evil twin suggests that it's the >well known Dutch frugality at work. I suspect that since Clean is lazy >and was originally a lower level language, they just didn't include it. > >I agree with Markus that if-then-else is nicer to read. Haskell get's this one >right over Clean. > I know different strokes for different people but I do not see why if-then should be easier to read. An excertp from a Haskell manual: == When many choices have to made guards can come in handy. Instead of: kindOfChar :: /Char -> String/ kindOfChar c = if isLower c then "lower" else if isUpper c then "upper" else if isDigit c then "digit" else "other" you can write: kindOfChar :: /Char -> String/ kindOfChar c | isLower c = "lower" | isUpper c = "upper" | isDigit c = "digit" | otherwise = "other" == S. Gonzi ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners