CACI International interview question

Count occurrences in an array