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 UAA07707; Tue, 15 Oct 2002 20:47:16 +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 UAA08177 for ; Tue, 15 Oct 2002 20:47:15 +0200 (MET DST) Received: from slave-dog.naughtydog.com (naughtydog200.brandx.net [209.55.75.200]) by concorde.inria.fr (8.11.1/8.11.1) with SMTP id g9FIlD524079; Tue, 15 Oct 2002 20:47:13 +0200 (MET DST) Received: from SMTP agent by mail gateway Tue, 15 Oct 2002 11:47:52 -0800 Received: from katn-dog (engstad@katn-dog.naughtydog.com [10.0.0.90]) by slave-dog.naughtydog.com (SGI-8.9.3/8.9.3) with ESMTP id LAA08325; Tue, 15 Oct 2002 11:47:37 -0700 (PDT) Content-Type: text/plain; charset="iso-8859-1" From: Pal-Kristian Engstad Organization: Naughty Dog, Inc. To: Eray Ozkural , Xavier Leroy , Oleg Subject: Re: [Caml-list] productivity improvement Date: Tue, 15 Oct 2002 11:47:36 -0700 User-Agent: KMail/1.4.3 Cc: Emmanuel Renieris , caml-list@inria.fr References: <20020716172916.4903.qmail@web10702.mail.yahoo.com> <20020719131039.A30060@pauillac.inria.fr> <200210151224.47272.erayo@cs.bilkent.edu.tr> In-Reply-To: <200210151224.47272.erayo@cs.bilkent.edu.tr> MIME-Version: 1.0 Message-Id: <200210151147.36156.engstad@naughtydog.com> Content-Transfer-Encoding: quoted-printable X-MIME-Autoconverted: from 8bit to quoted-printable by slave-dog.naughtydog.com id LAA08325 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Tuesday 15 October 2002 02:24 am, Eray Ozkural wrote: > For instance in a stock market prediction code I have been working on, = it > took no more than a couple of days to rewrite a large portion of the co= de > in Haskell that was previously written in C. The resulting code was > significantly shorter and more modular; allowing me to play with new > algorithms / metrics easily. The same would not be the case with C++. (= The > code isn't too Haskell specific and could be done as well in ocaml) I've found Haskell's use of IO monads to be "interesting", but terribly=20 restricting and hard to understand. I do like their operator and function= =20 overloading mechanisms though - I wish Ocaml would have something similar= (it=20 just gets tedius having to add a "." in every floating point calculation)= .=20 I've also had problems with converting stateful programs into Haskell. > That code I think went down from about 2500 lines to 500 lines which is= n't > bad. To attain that kind of improvement, you need a change in style. Th= e C > program apparently used lots of text I/O to transfer and store data bet= ween > modules. The Haskell program didn't have to. That's strange. How could the Haskell program not have to do IO? > It is also true that it is not correct to expect such improvements in c= ode > that is too simple. If all you want to do is to sum over an array of > integers, you can do it in C easily. Now, that is very true. PKE. --=20 _ =20 \`. P=E5l-Kristian Engstad, Senior Software Engineer, \ `| Naughty Dog, Inc., 1315 3rd Street Promenade,=20 __\ |`. Santa Monica, CA 90046, USA. (310) 752-1000 x799.=20 / /o mailto:engstad@naughtydog.com http://www.naughtydog.com / '~ mailto:mrengstad@yahoo.com http://www.engstad.com / ,' Go hang-gliding! ~' ------------------- 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