Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
* Difference between "let rec" and just "let"?
@ 2008-08-13 12:49 circ ular
  2008-08-13 13:52 ` [Caml-list] " Jean Krivine
  2008-08-13 15:17 ` Christophe TROESTLER
  0 siblings, 2 replies; 4+ messages in thread
From: circ ular @ 2008-08-13 12:49 UTC (permalink / raw)
  To: caml-list

what is the difference between "let rec" and just "let"? what does rec
stand for?

are the following defintions exactly the same? at least they seem to
give the same results...

# let rec cube x = x*x*x;;
val cube : int -> int = <fun>
# cube 12;;
- : int = 1728

# let cubex x = x*x*x;;
val cubex : int -> int = <fun>
# cubex 12;;
- : int = 1728
#


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

end of thread, other threads:[~2008-08-13 18:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-08-13 12:49 Difference between "let rec" and just "let"? circ ular
2008-08-13 13:52 ` [Caml-list] " Jean Krivine
2008-08-13 18:39   ` Andrej Bauer
2008-08-13 15:17 ` Christophe TROESTLER

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox