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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,15bb83df7cabf157 X-Google-Attributes: gid103376,public From: Brian Rogoff Subject: Re: is there a FAQ? Date: 1998/05/15 Message-ID: #1/1 X-Deja-AN: 353639705 References: <6ji9o8$5t6$1@nnrp1.dejanews.com> Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: 895269364 7643 bpr 206.184.139.132 Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 1998-05-15T00:00:00+00:00 List-Id: On Fri, 15 May 1998 adam@irvine.com wrote: > Johann Hibschman wrote: > > Is there a (convenient) way to write > > > > (map-into out-vector > > #'(lambda (x y) (+ x (sqrt y))) > > vector1 vector2) > > > > as I would in Common Lisp? (Or, with slight syntax changes, in ML?) > > ... snip ... > > A little more verbose than Common Lisp, but not that much, really. No > more than you'd expect for a strongly typed language. Actually, ML is quite strongly typed, and does mapping just as concisely as Common Lisp. The distinction is that ML is not *explicitly* typed, like Ada; the most general type is inferred and so you don't have to spell everything out, or instantiate generic functions. Lots of "researchy" languages do this. I found your Ada more than "a little more verbose" than the comparable code in ML or Haskell. Its clear that this is not so for all problems however, and sometimes that verbosity is a win. -- Brian