#include <bits/stdc++.h>
using namespace std;
const int maxn = 100 + 10;
int rang[maxn], mark[maxn];
vector<int> v[maxn];
pair<int, int> p[maxn];
int in(int a, int b, int c) {
  if (a < c && c < b)
    return 1;
  else
    return 0;
}
void dfs(int x, int color) {
  mark[x] = true;
  rang[x] = color;
  for (int i = 0; i < v[x].size(); i++) {
    int next = v[x][i];
    if (!mark[next])
      dfs(next, 3 - color);
    else if (rang[x] == rang[next]) {
      cout << "Impossible" << endl;
      exit(0);
    }
  }
}
int n, m;
int main() {
  cin >> n >> m;
  for (int i = 0; i < m; i++) {
    int h1, h2;
    cin >> h1 >> h2;
    h1--;
    h2--;
    p[i].first = min(h1, h2);
    p[i].second = max(h1, h2);
    for (int j = 0; j < i; j++) {
      if (p[i].first != p[j].first && p[i].second != p[j].second) {
        if (in(p[i].first, p[i].second, p[j].first) &&
            !in(p[i].first, p[i].second, p[j].second)) {
          v[i].push_back(j);
          v[j].push_back(i);
        } else if (in(p[i].first, p[i].second, p[j].second) &&
                   !in(p[i].first, p[i].second, p[j].first)) {
          v[i].push_back(j);
          v[j].push_back(i);
        }
      }
    }
  }
  for (int i = 0; i < m; i++)
    if (!mark[i]) dfs(i, 1);
  for (int i = 0; i < m; i++) {
    if (rang[i] == 1)
      cout << 'i';
    else
      cout << 'o';
  }
  return 0;
}
