I have an array of size 50 that holds random integers between 1 and 49.
I would like to be able to count the amount of times the numbers between 10 and 19 occur within the array.
<script type = "text/javascript">
var arr = [];
function getRandom( num ){
return Math.round(Math.random() * num)+1;
}
var counter = 0;
for (var i = 0; i < 50; i++) {
arr.push(getRandom( 49 ));
counter++;
}