func_code_string: #include <bits/stdc++.h>   using namespace std;   int n;   bool ison[100010];   char temp[100];   int q, t;   int isprime[100010];   int prime[100010];   vector<int> pr[100010];   void preprocess() {     fill(isprime, isprime + 100010, 0);     fill(ison, ison + 100010, false);     fill(prime, prime + 100010, -1);     for (int i = 2; i < 100010; i++) {       if (isprime[i]) {         continue;       }       pr[i].push_back(i);       for (int j = i + i; j < 100010; j += i) {         pr[j].push_back(i);         isprime[j] = i;       }     }   }   void solve1(int a) {     if (ison[a]) {       printf( Already on n );       return;     }     int len = pr[a].size();     int i;     for (i = 0; i < len; i++) {       int val = pr[a][i];       if (prime[val] == -1) {         continue;       } else {         printf( Conflict with %d n , prime[val]);         return;       }     }     for (i = 0; i < len; i++) {       int val = pr[a][i];       prime[val] = a;     }     ison[a] = true;     printf( Success n );   }   void solve2(int b) {     if (!ison[b]) {       printf( Already off n );       return;     }     int len = pr[b].size();     int i, val;     for (i = 0; i < len; i++) {       val = pr[b][i];       prime[val] = -1;     }     ison[b] = false;     printf( Success n );   }   int main() {     scanf( %d%d , &n, &q);     preprocess();     for (int i = 0; i < q; i++) {       scanf( %s , temp);       scanf( %d , &t);       if (temp[0] ==  + ) {         solve1(t);       } else {         solve2(t);       }     }     return 0;   }   