array1 has the data you want to count

array2 has the count of each number (ie: value)

If you know the value of the data entered, use that value as an array index to keep track of the total number. For example, let's say I have only 3 possible "answers".

Code:

int arrayList[SIZE] = { a bunch of numbers here, let's say 0,1,2 }
int answerCount[3];
// Set all "answerCount" values to 0, and then start counting:
for( x = 0; x < arrayListSize; x++ )
{
// arrayList[x] will have an answer in it, who's value will be
// only 0, 1, or 2.
// here, we're taking the value of "arrayList[x]"
// and using it as the index for the second array
// and incrementing that count
answerCount[ arrayList[x] ]++;
}

Quzah.