#include <bits/stdc++.h>
const int MAX = 100005;
bool sim(int y) {
  if (y < 2) {
    return false;
  }
  int i = 2;
  for (;;) {
    if ((i * i) > y) {
      return true;
    }
    if (y == (y / i * i)) {
      return false;
    }
    i++;
  }
}
int main() {
  int kolsim = 0;
  int* simple = new int[MAX];
  int* onoff = new int[MAX + 1];
  int** conflict = new int*[MAX];
  for (int gh = 0; gh < MAX; gh++) {
    conflict[gh] = new int[MAX / 500 + 3];
  }
  for (int i = 0; i <= MAX; i++) {
    if (sim(i)) {
      simple[kolsim] = i;
      kolsim++;
    }
  }
  for (int i = 0; i < MAX; i++)
    for (int j = 0; j < (MAX / 500 + 3); j++) conflict[i][j] = 0;
  for (int i = 0; i <= MAX; i++) {
    onoff[i] = 0;
  }
  int m;
  scanf("%d", &m);
  scanf("%d", &m);
  for (int hjk = 0; hjk < m; hjk++) {
    char c = 'l';
    int number;
    while ((c != '+') && (c != '-')) {
      scanf("%c", &c);
    }
    scanf("%d", &number);
    if (c == '+') {
      if (onoff[number] == 1) {
        printf("Already on\n");
        continue;
      }
      bool conf = false;
      int i = 0;
      int tmp = number;
      int tmp2 = number;
      while ((simple[i] * simple[i]) <= number) {
        int sh = 0;
        while (number == (number / simple[i] * simple[i])) {
          number /= simple[i];
          sh++;
        }
        if (sh == 0) {
        } else {
          for (int j = 0; j < (MAX / 500 + 3); j++) {
            if (conflict[i][j] == 1) {
              conf = true;
              int confside;
              confside = 500 * j;
              while (confside != (confside / simple[i] * simple[i])) {
                confside++;
              }
              while ((onoff[confside] == 0)) {
                confside += simple[i];
              }
              if (conf) {
                printf("Conflict with %d\n", confside);
              }
              break;
            }
          }
        }
        i++;
        if (conf) {
          break;
        }
      }
      if (conf) {
        continue;
      }
      if (number == 1) {
        printf("Success\n");
        onoff[tmp2] = 1;
        int i = 0;
        while (tmp != 1) {
          if (tmp == (tmp / simple[i] * simple[i])) {
            tmp /= simple[i];
            conflict[i][tmp2 / 500] = 1;
          } else {
            i++;
          }
        }
        continue;
      }
      int verx = kolsim - 1;
      int niz = 0;
      while ((verx - niz) > 4) {
        if (number > simple[(verx + niz) / 2]) {
          niz = (verx + niz) / 2;
        } else {
          verx = (verx + niz) / 2;
        }
      }
      for (i = niz; i <= verx; i++) {
        if (simple[i] == number) {
          break;
        }
      }
      for (int j = 0; j < (MAX / 500 + 3); j++) {
        if (conflict[i][j] == 1) {
          conf = true;
          int confside;
          confside = 500 * j;
          while (confside != (confside / simple[i] * simple[i])) {
            confside++;
          }
          while ((onoff[confside] == 0)) {
            confside += simple[i];
          }
          if (conf) {
            printf("Conflict with %d\n", confside);
          }
        }
        if (conf) {
          break;
        }
      }
      if (!conf) {
        printf("Success\n");
        onoff[tmp2] = 1;
        int i = 0;
        while (tmp != 1) {
          if (tmp == (tmp / simple[i] * simple[i])) {
            tmp /= simple[i];
            conflict[i][tmp2 / 500] = 1;
          } else {
            if ((simple[i] * simple[i]) > tmp) {
              int verx = kolsim - 1;
              int niz = 0;
              while ((verx - niz) > 4) {
                if (tmp > simple[(verx + niz) / 2]) {
                  niz = (verx + niz) / 2;
                } else {
                  verx = (verx + niz) / 2;
                }
              }
              int k;
              for (k = niz; k <= verx; k++) {
                if (simple[k] == tmp) {
                  break;
                }
              }
              i = k;
            } else {
              i++;
            }
          }
        }
      }
    } else {
      if (onoff[number] == 0) {
        printf("Already off\n");
        continue;
      }
      printf("Success\n");
      onoff[number] = 0;
      int i = 0;
      int tmp = number;
      int tmp2 = number;
      while ((simple[i] * simple[i]) <= number) {
        if (number != (number / simple[i] * simple[i])) {
          i++;
          continue;
        }
        while (number == (number / simple[i] * simple[i])) {
          number /= simple[i];
        }
        int prov = tmp / 500;
        conflict[i][prov] = 0;
        int step = 1;
        int simplei = simple[i];
        int vpred = (prov * 500 + 500);
        if (vpred > MAX) {
          vpred = MAX;
        }
        int npred = (prov * 500);
        if (npred != (npred / simplei * simplei)) {
          npred += (simplei - npred % simplei);
        }
        step = simplei;
        for (int j = npred; j < vpred; j += step) {
          if ((onoff[j] == 1)) {
            conflict[i][prov] = 1;
          }
        }
      }
      int verx = kolsim - 1;
      int niz = 0;
      while ((verx - niz) > 4) {
        if (number > simple[(verx + niz) / 2]) {
          niz = (verx + niz) / 2;
        } else {
          verx = (verx + niz) / 2;
        }
      }
      for (i = niz; i <= verx; i++) {
        if (simple[i] == number) {
          break;
        }
      }
      int prov = tmp / 500;
      conflict[i][prov] = 0;
      int step = 1;
      int simplei = simple[i];
      int vpred = (prov * 500 + 500);
      if (vpred > MAX) {
        vpred = MAX;
      }
      int npred = (prov * 500);
      if (npred != (npred / simplei * simplei)) {
        npred += (simplei - npred % simplei);
      }
      step = simplei;
      for (int j = npred; j < vpred; j += step) {
        if ((onoff[j] == 1)) {
          conflict[i][prov] = 1;
        }
      }
    }
  }
  return 0;
}
