Once I took from the user 10 numbers and placed them in an array of size 10, I want to check for each number in the array if it is prime or not and count how many prime numbers there is. Here is what I tried to do:
int count=0;
for(int r=0;r<10;r++) {
for(int t=2; t < array[r];t++) {
if(array[r] % t != 0) {
count++;
}
}
}
array[r] is already filled with numbers at this point, so all I need to do is to check for each number if it is prime or not.