#include <stdio.h>
#include <stdlib.h>
#include <time.h>
int main( void ) {
int n[ 10 ] ;
for ( int i = 0 ; i < 10 ; i++ ) {
printf ( "%d numero: %d\n " , i
, n
[ i
] ) ; }
for ( int i = 0 ; i < 10 ; i++ ) {
int j = 2 ;
for ( ; j < n[ i] ; j++ ) if ( n[ i] % j == 0 ) break ;
if ( n
[ i
] == j
) printf ( "O numero %d e primo\n " , n
[ i
] ) ; }
}
//https://pt.stackoverflow.com/q/44537/101
I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxzdGRsaWIuaD4KI2luY2x1ZGUgPHRpbWUuaD4KCmludCBtYWluKHZvaWQpIHsKICAgIGludCBuWzEwXTsKICAgIHNyYW5kKHRpbWUoTlVMTCkpOwogICAgZm9yIChpbnQgaSA9IDA7IGkgPCAxMDsgaSsrKSB7CiAgICAgICAgbltpXSA9IHJhbmQoKSAlIDI1MDsKICAgICAgICBwcmludGYoIiVkIG51bWVybzogJWRcbiIsIGksIG5baV0pOwogICAgfQogICAgcHJpbnRmKCJcbiIpOwogICAgZm9yIChpbnQgaSA9IDA7IGkgPCAxMDsgaSsrKSB7CiAgICAJaW50IGogPSAyOwogICAgICAgIGZvciAoOyBqIDwgbltpXTsgaisrKSBpZiAobltpXSAlIGogPT0gMCkgYnJlYWs7CiAgICAgICAgaWYgKG5baV0gPT0gaikgcHJpbnRmKCJPIG51bWVybyAlZCBlIHByaW1vXG4iLCBuW2ldKTsKICAgIH0KfQoKLy9odHRwczovL3B0LnN0YWNrb3ZlcmZsb3cuY29tL3EvNDQ1MzcvMTAx