#include <bits/stdc++.h>
using namespace std;
int intersect(int a, int b, int c, int d) {
  if ((c > a) && (c < b) && ((d < a) || (d > b))) return 1;
  if ((d > a) && (d < b) && ((c < a) || (c > b))) return 1;
  return 0;
}
int main() {
  int n, m, a, b, E[120][2], A[110][110];
  cin >> n >> m;
  memset(A, 0, sizeof(A));
  for (int i = 0; i < m; i++) {
    int a, b;
    cin >> a >> b;
    E[i][0] = min(a, b);
    E[i][1] = max(a, b);
    for (int j = 0; j < i; j++) {
      if (intersect(E[i][0], E[i][1], E[j][0], E[j][1])) {
        A[i][j] = A[j][i] = 1;
      }
    }
  }
  int seen[110], nseen = 0, cur = 0, label[110];
  memset(seen, 0, sizeof(seen));
  while (nseen < m) {
    while (seen[cur]) cur++;
    queue<int> Q;
    Q.push(cur);
    seen[cur] = 1;
    label[cur] = 0;
    nseen++;
    while (!Q.empty()) {
      int i = Q.front();
      Q.pop();
      for (int j = 0; j < m; j++) {
        if (A[i][j]) {
          if (seen[j]) {
            if (label[j] != label[i] ^ 1) {
              cout << "Impossible\n";
              return 0;
            }
          } else {
            seen[j] = 1;
            label[j] = label[i] ^ 1;
            Q.push(j);
            nseen++;
          }
        }
      }
    }
  }
  char lab[2] = {'o', 'i'};
  for (int i = 0; i < m; i++) cout << lab[label[i]];
  cout << endl;
  return 0;
}
