<div id="container">
<div>
<div>
</div>
</div>
<div>
<div>
</div>
</div>
<div>
<div>
</div>
</div>
</div>
$('#container').find('div') will also include those inner divs.
How to fetch only the 3 top-level divs?
You can use jQuery’s children([expr]) function to do this.
Something like