#include <bits/stdc++.h>
using namespace std;
const int MAXINT = 2147483647;
const long long MAXLONGINT = 9223372036854775807;
const int MAX = 300000;
long long n, a, s;
vector<long long> ans, v[MAX];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a;
    v[a].push_back(i);
  }
  s = 0;
  while (n > 0) {
    if (!v[s].empty()) {
      ans.push_back(v[s][v[s].size() - 1]);
      v[s].pop_back();
      s++;
      n--;
    } else {
      if (s >= 3)
        s -= 3;
      else
        break;
    }
    if (n == 0) break;
  }
  if (n == 0) {
    cout << "Possible\n";
    for (int i = 0; i < ans.size(); i++) cout << ans[i] << ' ';
    cout << '\n';
  } else
    cout << "Impossible\n";
  return 0;
}
