What is meaning of "(function(window, undefined){})(window)" in JavaScript?
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/2716069/how-does-this-javascript-jquery-syntax-work-function-window-undefined">How does this JavaScript/JQuery Syntax work: (function( window, undefined ) { })(window)?</a>  </p>
</blockquote>



<pre><code>(function(window, undefined){})(window);
</code></pre>

<p>What is the meaning of this code? I have seen it in many documents, especially in jQuery documents.</p>

<p>How does this work, and why is it defined thus?</p>
