Can anyone explain the difference between closure and anonymous functions?

Posted by Stick it to THE MAN on Stack Overflow See other posts from Stack Overflow or by Stick it to THE MAN
Published on 2010-01-25T09:12:29Z Indexed on 2010/05/27 19:21 UTC
Read the original article Hit count: 250

Filed under:

I am relatively new to Javascript. I understand the concept of anonymous functions - but closures seem less clear. The similarity between the two (in my mind atleast), is confusing.

Could someone explain the difference? (preferrably, with some code snippet, to illustrate the points clearer).

© Stack Overflow or respective owner

Related posts about JavaScript