#include <bits/stdc++.h>
using namespace std;
const long long N = 105;
string str;
bool used[N / 2];
int main() {
  long long k, i, n, j;
  cin >> k >> str;
  n = str.size();
  for (i = 0; i < n; i++)
    if (str[i] != '?') used[str[i] - 'a'] = true;
  for (i = 0; i < n; i++)
    if (str[i] == '?' && str[n - i - 1] != '?') str[i] = str[n - i - 1];
  for (i = 0; i < n; i++) {
    if (i >= n - i - 1 && str[i] == '?') {
      for (j = k - 1; j >= 1; j--)
        if (!used[j]) break;
      str[i] = str[n - i - 1] = j + 'a';
      used[j] = true;
    }
  }
  for (i = 0; i < k; i++) {
    if (!used[i]) {
      cout << "IMPOSSIBLE\n";
      return 0;
    }
  }
  for (i = 0; i < n; i++) {
    if (str[i] == '?') {
      cout << "IMPOSSIBLE\n";
      return 0;
    }
  }
  string str1 = str;
  reverse(str1.begin(), str1.end());
  if (str1 != str) str = "IMPOSSIBLE\n";
  cout << str << "\n";
  return 0;
}
