why are javascript functions like this
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/3921922/what-does-this-mean-function-x-y-a-b-in-javascript">What does this mean? (function (x,y)){&hellip;}){a,b); in JavaScript</a>  </p>
</blockquote>



<p>I am a starter to javascript. I know to write JS userdefined functions. 
But recently I came across some thing that I can’t recognize. Can anyone explain to me what this is? </p>

<pre><code>(function( window, undefined ) {

    var jQuery = (function() {
    });
           window.jQuery = window.$ = jQuery;
})(window);
</code></pre>

<p>What is the meaning of this? When I Google javascript functions I am getting only</p>

<pre><code>function foo(){ 
    alert("This is an alert"); 
}
</code></pre>

<p>I know to use these type of functions </p>
