#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  scanf("%d", &n);
  set<pair<int, int> > st;
  for (int i = 0; i < n; ++i) {
    int x;
    scanf("%d", &x);
    st.insert({x, i});
  }
  int x = -1;
  vector<int> ans;
  while (x >= -1) {
    auto it = st.lower_bound({x + 1, -1});
    if (it != st.end() and it->first == x + 1) {
      ans.emplace_back(it->second);
      st.erase(it);
      x++;
    } else {
      x -= 3;
    }
  }
  if (st.empty()) {
    cout << "Possible\n";
    for (const int &x : ans) printf("%d ", x + 1);
  } else {
    cout << "Impossible\n";
  }
}
