#include <bits/stdc++.h>
using namespace std;
int k, len;
string str;
bool used[30];
int cnt;
int main() {
  cin >> k >> str;
  len = str.length();
  for (int i = 0; i < len; i++)
    if (str[i] != '?') used[str[i] - 'a'] = true;
  for (int i = k - 1; i >= 0; i--) cnt += !used[i];
  for (int i = 0; i < (len + 1) / 2; i++)
    if (str[i] == '?' && str[len - i - 1] == '?') --cnt;
  if (cnt > 0) {
    puts("IMPOSSIBLE");
    return 0;
  }
  for (int i = 0; i < (len + 1) / 2; i++)
    if (str[i] != '?' && str[len - i - 1] != '?' &&
        str[i] != str[len - i - 1]) {
      puts("IMPOSSIBLE");
      return 0;
    }
  for (int i = 0; i < len; i++) {
    if (str[i] == '?') {
      if (str[len - i - 1] == '?') {
        if (cnt < 0) {
          ++cnt;
          str[i] = 'a';
        } else {
          for (int j = 0; j < k; j++)
            if (!used[j]) {
              used[j] = true;
              str[i] = 'a' + j;
              break;
            }
        }
      } else {
        str[i] = str[len - i - 1];
      }
    }
  }
  cout << str << endl;
  return 0;
}
