What's the difference between $(document).ready(…) and $(function() {}) in jQuery?
<p>What's the difference between:</p>

<pre><code>$(document).ready(function() {// Do something});
</code></pre>

<p>and</p>

<pre><code>$(function() {//Do something});
</code></pre>

<p>in jQuery?</p>
