#include <stdio.h>
int main() {
int i, numero;
do {
printf("Informe um numero primo maior que 1:"); } while (numero <= 1);
for (i = 2; i < numero; i++) {
if (numero % i == 0) {
break;
}
}
if (numero == i) {
printf("Numero primo %d", numero
); } else {
printf("Numero não primo %d", numero
); }
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgbWFpbigpIHsKICAgIGludCBpLCBudW1lcm87CiAgICBkbyB7CiAgICAgICAgcHJpbnRmKCJJbmZvcm1lIHVtIG51bWVybyBwcmltbyBtYWlvciBxdWUgMToiKTsKICAgICAgICBzY2FuZigiJWQiLCAmbnVtZXJvKTsKICAgIH0gd2hpbGUgKG51bWVybyA8PSAxKTsKICAgIGZvciAoaSA9IDI7IGkgPCBudW1lcm87IGkrKykgewogICAgCWlmIChudW1lcm8gJSBpID09IDApIHsKICAgIAkJYnJlYWs7CiAgICAJfQogICAgfQogICAgaWYgKG51bWVybyA9PSBpKSB7CiAgICAgICAgcHJpbnRmKCJOdW1lcm8gcHJpbW8gJWQiLCBudW1lcm8pOwogICAgfSBlbHNlIHsKICAgICAgICBwcmludGYoIk51bWVybyBuw6NvIHByaW1vICVkIiwgbnVtZXJvKTsKICAgIH0KfQ==