#include <bits/stdc++.h>
using namespace std;
int n;
string s;
map<char, bool> m;
int main() {
  cin >> n >> s;
  char pl = 'a';
  int sum = 0, sum2 = 0;
  int len = s.size();
  int book = 0;
  for (int i = 0; i < len / 2; ++i) {
    if (isalpha(s[i])) {
      if (!m[s[i]]) {
        m[s[i]] = 1;
        sum2++;
      }
      if (s[len - i - 1] == '?') {
        s[len - i - 1] = s[i];
      } else if (s[i] != s[len - i - 1]) {
        puts("IMPOSSIBLE");
        return 0;
      }
    }
  }
  for (int i = len / 2; i < len; ++i) {
    if (isalpha(s[i])) {
      if (!m[s[i]]) {
        m[s[i]] = 1;
        sum2++;
      }
      if (s[len - i - 1] == '?') {
        s[len - i - 1] = s[i];
      } else if (s[i] != s[len - i - 1]) {
        puts("IMPOSSIBLE");
        return 0;
      }
    } else
      sum++;
  }
  sum2 = n - sum2;
  if (sum2 > sum) {
    puts("IMPOSSIBLE");
    return 0;
  }
  int tot = sum - sum2;
  for (int i = 0; i <= len / 2; ++i) {
    if (s[i] == '?') {
      if (tot) {
        s[i] = 'a';
        s[len - i - 1] = 'a';
        tot--;
      } else {
        while (m[pl]) pl++;
        s[i] = pl;
        s[len - i - 1] = pl;
        m[pl] = 1;
      }
    }
  }
  cout << s << endl;
  return 0;
}
