#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const long long LINF = 0x3f3f3f3f3f3f3f3fll;
const long double pi = acos(-1);
const int MOD = 1e9 + 7;
const int N = 110;
vector<int> g[N];
int n, m;
bool inter(pair<int, int> x, pair<int, int> y) {
  if (x.first > x.second) swap(x.first, x.second);
  if (y.first > y.second) swap(y.first, y.second);
  if (x.first <= y.first and x.second >= y.second) return true;
  if (y.first <= x.first and y.second >= x.second) return true;
  if (x.second <= y.first) return true;
  if (y.second <= x.first) return true;
  return false;
}
int cor[N];
int pau = 0;
int dfs(int u, int col) {
  cor[u] = col;
  int ncol = 2;
  if (col == 2) ncol = 1;
  for (int v : g[u])
    if (!cor[v]) dfs(v, ncol);
  return 0;
}
int main() {
  scanf("%d %d", &n, &m);
  vector<pair<int, int> > coco;
  for (int i = 0; i < m; i++) {
    int u, v;
    scanf("%d %d", &u, &v);
    coco.push_back(make_pair(u, v));
  }
  for (int i = 0; i < m; i++)
    for (int j = i + 1; j < m; j++) {
      if (!inter(coco[i], coco[j])) g[i].push_back(j), g[j].push_back(i);
    }
  for (int i = 0; i < m; i++)
    if (!cor[i]) dfs(i, 1);
  for (int i = 0; i < m; i++)
    for (int v : g[i])
      if (cor[i] == cor[v]) {
        cout << "Impossible" << endl;
        return 0;
      }
  for (int i = 0; i < m; i++)
    if (cor[i] == 1)
      cout << "i";
    else
      cout << "o";
  cout << endl;
  return 0;
}
