caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Simple factorial
@ 2007-01-23 18:50 Lucas Holland
  2007-01-23 19:04 ` [Caml-list] " Tom
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Lucas Holland @ 2007-01-23 18:50 UTC (permalink / raw)
  To: caml-list

Hello,

I've just started learning O'Caml. I've written a simple factorial  
function (no checking whether n is 1 etc.):

let rec factorial n =
	n * factorial (n-1);;

When I call this function with let's say 5 as an argument, I get an  
overflow error message.

Any ideas?

chell


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-01-24 17:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-23 18:50 Simple factorial Lucas Holland
2007-01-23 19:04 ` [Caml-list] " Tom
2007-01-23 19:10 ` robert
2007-01-23 19:11 ` Dário Abdulrehman
2007-01-23 19:50 ` Till Varoquaux

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).