#include <stdio.h>
#define N 50
int main()
{
int i, j;
int n, a[N + 1];
for (i = 0; i < N; ++i)a[i] = 1;
for (i = 2; i <= N; ++i)
for (j = 2 * i; j <= N; j += i)
a[j] = 0;
for (i
= 2; i
<= N
; ++i
)if (a
[i
] == 1)printf("%d ", i
); return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CiNkZWZpbmUgTiA1MAppbnQgbWFpbigpCnsKICBpbnQgaSwgajsKICBpbnQgbiwgYVtOICsgMV07CiAgZm9yIChpID0gMDsgaSA8IE47ICsraSlhW2ldID0gMTsKICBwcmludGYoIm4gPSAiKTsKICBzY2FuZigiJWQiLCAmbik7CiAgZm9yIChpID0gMjsgaSA8PSBOOyArK2kpCiAgICBmb3IgKGogPSAyICogaTsgaiA8PSBOOyBqICs9IGkpCiAgICAgIGFbal0gPSAwOwogIGZvciAoaSA9IDI7IGkgPD0gTjsgKytpKWlmIChhW2ldID09IDEpcHJpbnRmKCIlZCAiLCBpKTsKICByZXR1cm4gMDsKfQ==