func_code_string: #include <bits/stdc++.h>   int p, prime[100005], count[100005][20];   void Prime() {     int i, j;     for (i = 2, p = 0; i < 100005; i++) {       for (j = 2; j <= sqrt(i); j++)         if (i % j == 0) break;       if (j > sqrt(i)) prime[p++] = i;     }   }   void Count() {     int i, j;     memset(count, 0, sizeof(count));     for (i = 0; i < p; i++)       for (j = prime[i]; j < 100005; j += prime[i])         count[j][++count[j][0]] = prime[i];   }   int main() {     Prime();     Count();     char sym;     int n, m, i, j, ind, flag[100005], num[100005];     while (scanf( %d%d , &n, &m) != EOF) {       memset(flag, 0, sizeof(flag));       memset(num, 0, sizeof(num));       for (i = 0; i < m; i++) {         getchar();         scanf( %c %d , &sym, &ind);         if (sym ==  + ) {           if (flag[ind])             printf( Already on n );           else {             for (j = 1; j <= count[ind][0]; j++)               if (num[count[ind][j]]) break;             if (j > count[ind][0]) {               printf( Success n );               flag[ind] = 1;               for (j = 1; j <= count[ind][0]; j++) num[count[ind][j]] = ind;             } else               printf( Conflict with %d n , num[count[ind][j]]);           }         } else {           if (!flag[ind])             printf( Already off n );           else {             printf( Success n );             flag[ind] = 0;             for (j = 1; j <= count[ind][0]; j++) num[count[ind][j]] = 0;           }         }       }     }     return 0;   }   