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 JAA32235; Tue, 23 Dec 2003 09:26:37 +0100 (MET) 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 JAA32113 for ; Tue, 23 Dec 2003 09:26:35 +0100 (MET) Received: from bob.west.spy.net (mail.west.spy.net [66.149.231.226]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id hBN8QYv24027 for ; Tue, 23 Dec 2003 09:26:34 +0100 (MET) Received: from [192.168.1.50] (dustinti.west.spy.net [192.168.1.50]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client did not present a certificate) by bob.west.spy.net (Postfix) with ESMTP id 9143059D2; Tue, 23 Dec 2003 00:26:29 -0800 (PST) In-Reply-To: References: <1072152186.59938.30.camel@tylere> <0D3B5ECF-350D-11D8-A8F7-000393CB0F1E@spy.net> Mime-Version: 1.0 (Apple Message framework v609) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: Content-Transfer-Encoding: 7bit Cc: caml-list@inria.fr From: Dustin Sallings Subject: Re: [Caml-list] Frustrated Beginner Date: Tue, 23 Dec 2003 00:26:20 -0800 To: Tyler Eaves X-Mailer: Apple Mail (2.609) X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 primes:01 bagley:01 cae:99 ocaml:01 side-effects:02 syntax:02 her:97 wrote:03 tail:03 fingerprint:04 stuff:05 probably:05 it'll:05 guess:06 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Dec 22, 2003, at 23:23, Tyler Eaves wrote: > This makes since in general. I'm guess h and t correspond to the head > and tail of the lift. It'll probably make more sense tomorrow. It's > 2:11 here, and I'd planned to be asleep two hours ago. The replies > have kept me up ;) > > Based on what I've learned, I've tried to write a simple prime number > finder. It doesn't actually *work* or anything (Syntax Error on line > 23, can't figure out why...), but I think I've figured some of this > stuff out, kinda. I'm encouraged at least. I responded to this off-list. Basically it's learning to program without side-effects. I provided a few side-effect-free implementations which can be seen here: http://bleu.west.spy.net/~dustin/tmp/primes.ml.html I rather like this, as well: http://www.bagley.org/~doug/ocaml/Notes/okoans.shtml -- SPY My girlfriend asked me which one I like better. pub 1024/3CAE01D5 1994/11/03 Dustin Sallings | Key fingerprint = 87 02 57 08 02 D0 DA D6 C8 0F 3E 65 51 98 D8 BE L_______________________ I hope the answer won't upset her. ____________ ------------------- 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