// Gets the number of elements with class yourClass
var numItems = $('.yourclass').length
<div class="wrapper">
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
<div class="item"></div>
</div>
<script>
alert($('.wrapper').children('.item').length)
</script>