#include <bits/stdc++.h>
using namespace std;
bool used[26];
int main() {
  int k;
  char buffer[256];
  scanf("%d", &k);
  gets(buffer);
  gets(buffer);
  int len = strlen(buffer);
  for (int i = 0; buffer[i] != 0; ++i) {
    if (buffer[i] - 'a' >= k) {
      printf("IMPOSSIBLE\n");
      return 0;
    }
    if (buffer[i] != '?' && buffer[len - i - 1] != '?') {
      if (buffer[i] == buffer[len - i - 1]) {
        used[buffer[i] - 'a'] = true;
      } else {
        printf("IMPOSSIBLE\n");
        return 0;
      }
    } else if (buffer[i] == '?' && buffer[len - i - 1] != '?') {
      buffer[i] = buffer[len - i - 1];
      used[buffer[i] - 'a'] = true;
    } else if (buffer[i] != '?' && buffer[len - i - 1] == '?') {
      buffer[len - i - 1] = buffer[i];
      used[buffer[i] - 'a'] = true;
    }
  }
  for (int i = len / 2; buffer[i] != 0; ++i) {
    if (buffer[i] == '?') {
      int j = 0;
      for (j = k - 1; j >= 0; --j) {
        if (!used[j]) {
          break;
        }
      }
      if (j >= 0) {
        used[j] = true;
        buffer[i] = 'a' + j;
        buffer[len - i - 1] = buffer[i];
      } else {
        buffer[i] = buffer[len - i - 1] = 'a';
      }
    }
  }
  for (int i = 0; i < k; ++i) {
    if (!used[i]) {
      printf("IMPOSSIBLE\n");
      return 0;
    }
  }
  printf("%s\n", buffer);
  return 0;
}
