Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Closures

Name: Anonymous 2011-05-23 0:34

can someone explain them to me.. I'm thinken they might be simple but my pee sized brain can't comprehend most definitions off of google

Name: Anonymous 2011-05-23 1:17

>>3
z is a closure of add. This also means that the syntax (add 1) 2 is equivalent to add 1 2.
It also means you can't have &rest, &key and dynamic typing. It also means you have a duplicate functionality (a sign of bad design), which is already handled by lambda.


$ ghci
GHCi, version 6.8.2: http://www.haskell.org/ghc/  :? for help
Loading package base ... linking ... done.
Prelude> let fac 1 = 1; fac n = n * (fac n-1)
Prelude> (fac 4)
*** Exception: stack overflow
Prelude>

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List