#include <stdio.h>
int main() {
int a = 0;
int ret = 0;
int c = 0;
for (a = 100; a < 1000; a++) {
int count = 0;
int b = 0;
for (b = 1; b < a; b++) {
ret = a % b;
if (ret == 0) {
count++;
}
if (count > 1) {
//printf("%d\n", a);打印不是质数
c++;
break;
}
}
}
printf("%d", 900 - c);//900-不是质数
return 0;
}
int main() {
int a = 0;
int ret = 0;
int c = 0;
for (a = 100; a < 1000; a++) {
int count = 0;
int b = 0;
for (b = 1; b < a; b++) {
ret = a % b;
if (ret == 0) {
count++;
}
if (count > 1) {
//printf("%d\n", a);打印不是质数
c++;
break;
}
}
}
printf("%d", 900 - c);//900-不是质数
return 0;
}