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 XAA19278; Wed, 10 Jul 2002 23:16:05 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id XAA19270 for ; Wed, 10 Jul 2002 23:16:04 +0200 (MET DST) Received: from jah.cs.unm.edu (mail.cs.unm.edu [64.106.20.33]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id g6ALG3b15469 for ; Wed, 10 Jul 2002 23:16:03 +0200 (MET DST) Received: from amanda.cs.unm.edu ([64.106.20.36] ident=wneumann) by jah.cs.unm.edu with esmtp (Exim 3.36 #2) id 17SOoc-0001bM-00; Wed, 10 Jul 2002 15:16:02 -0600 Date: Wed, 10 Jul 2002 15:16:01 -0600 (MDT) From: "William D. Neumann" To: "Alexander V.Voinov" cc: caml-list@inria.fr Subject: Re: [Caml-list] Re: Sieve of Eratosthenes Performance: various languages In-Reply-To: <20020710.134732.63116839.avv@quasar.ipa.nw.ru> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Well, let's face it. This particular problem doesn't do much to address Oleg's (C vs. OCaml productivity ) question at all. And I wasn't posting my solution as an example of increased productivity either -- I was simply venting a bit (you have to understand, I'm a cryptographer, so seeing times in the minutes and seconds for generating the first 5000 primes is enough to make my skin crawl). Anyway, you don't see the point of using OCaml _solely_ as a Pascal with GC, and I don't see the point of writing bad code, simply for the sake of keeping it purely functional (after all, slow execution and sexy code isn't a productivity boost either). Still, your second point is very valid -- If the best I can do to generate a stream of primes in a functional manner is 250/second, something is wrong, and I'm going to need a better way of doing things. And with OCaml I can do that effortlessly, even if the rest of my code is functional out the wazoo. William D. Neumann On Wed, 10 Jul 2002, Alexander V.Voinov wrote: > Hi William, > > But it is completely imperative. As I understand, the original Oleg's > concern was that he doesn't see a point in learning something which > doesn't bring any benefit over C++. Personally, I don't see a point > in using OCaml _solely_ as a Pascal with GC. > > The only reason which justifies for me your quoted exercise is that > when you deadly need an efficient imperative part in your program you > can (quite likely) achieve this without leaving the language (to a C > extension or whatever). > > Alexander --- "The magnum opus of rms and his Foundation is called 'GNU', a project to completely rewrite the propritorially soiled Unix operating system. (Apparently, 'GNU' stands for "Gnu's Not Unix", and is proudly held to be the world's first 'recursive acronym'. Which, of course, proves that rms didn't get out enough in his youth.) -- Nick Roberts ------------------- 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