#include <bits/stdc++.h>
using namespace std;
vector<bool> mark;
int main() {
  int k;
  cin >> k;
  string s;
  cin >> s;
  int n = s.size();
  mark.assign(k, 0);
  for (int i = 0; i < n; i++) {
    if (s[i] != '?') {
      if ((s[i] - 'a') >= k) {
        printf("IMPOSSIBLE");
        return 0;
      }
      mark[s[i] - 'a'] = true;
    }
  }
  int p = n / 2;
  vector<int> ind;
  for (int i = 0; i < p; i++) {
    if (s[i] == '?' && s[n - 1 - i] == '?') {
      ind.push_back(i);
    } else if (s[i] == '?') {
      s[i] = s[n - 1 - i];
    } else if (s[n - 1 - i] == '?') {
      s[n - 1 - i] = s[i];
    } else if (s[i] != s[n - 1 - i]) {
      printf("IMPOSSIBLE");
      return 0;
    }
  }
  if (n % 2 == 1) {
    if (s[n / 2] == '?') {
      ind.push_back(n / 2);
    }
  }
  vector<char> ind2;
  for (int i = 0; i < mark.size(); i++) {
    if (!mark[i]) {
      ind2.push_back('a' + i);
    }
  }
  if (ind2.size() > ind.size()) {
    printf("IMPOSSIBLE");
    return 0;
  } else {
    int dl = ind.size() - ind2.size();
    for (int i = 0; i < dl; i++) {
      ind2.push_back('a');
    }
  }
  sort(ind2.begin(), ind2.end());
  for (int i = 0; i < ind2.size(); i++) {
    int y = ind[i];
    if (y == n / 2)
      s[y] = ind2[i];
    else {
      s[y] = s[n - 1 - y] = ind2[i];
    }
  }
  cout << s;
  return 0;
}
