#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 15;
int present[255];
int main() {
  int k;
  string s;
  cin >> k >> s;
  int n = s.size();
  int mid = (n / 2);
  vector<pair<int, int> > v;
  bool is = 1;
  for (int i = 0; i < n; ++i) {
    if (s[i] != '?') {
      int val = s[i];
      present[val] = 1;
      if (val - 'a' >= k) {
        is = 0;
      }
    }
  }
  for (int i = 0; i < mid; ++i) {
    int j = n - i - 1;
    if (s[i] == '?' && s[j] == '?') {
      v.push_back(make_pair(i, j));
    } else if (s[i] == '?' || s[j] == '?') {
      char c = s[i];
      if (c == '?') c = s[j];
      s[i] = s[j] = c;
    }
    if (s[i] != s[j]) {
      is = 0;
    }
  }
  if (n & 1) {
    if (s[mid] == '?') v.push_back(make_pair(mid, mid));
  }
  int sum = k;
  for (int i = 'a'; i <= 'a' + k - 1; ++i) {
    if (present[i]) --sum;
  }
  if (sum > v.size()) is = 0;
  int c = char('a' + k - 1);
  for (int i = v.size() - 1; i >= 0; --i) {
    while (c > 'a') {
      if (present[c])
        --c;
      else
        break;
    }
    int l = v[i].first, r = v[i].second;
    s[l] = s[r] = c;
    present[c] = 1;
  }
  if (!is) {
    printf("IMPOSSIBLE\n");
    return 0;
  }
  cout << s << endl;
}
