#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, na = 0, nc = 0, ng = 0, nt = 0, nw = 0;
  string s;
  cin >> n >> s;
  if (n % 4 != 0)
    cout << "===" << endl;
  else {
    for (int i = 0; i < n; i++) {
      if (s[i] == 'A') na++;
      if (s[i] == 'T') nt++;
      if (s[i] == 'C') nc++;
      if (s[i] == 'G') ng++;
      if (s[i] == '?') nw++;
    }
    if (nw == 0) {
      if (na == nc && nt == nc && nt == ng)
        cout << s << endl;
      else
        cout << "===" << endl;
    } else {
      while (nw > -0) {
        for (int i = 0; i < n; i++) {
          int mn = min(min(na, nt), min(nc, ng));
          if (s[i] == '?' && mn == na) {
            s.erase(i, 1);
            s.insert(i, "A");
            nw--;
            na++;
          }
          if (s[i] == '?' && mn == nc) {
            s.erase(i, 1);
            s.insert(i, "C");
            nw--;
            nc++;
          }
          if (s[i] == '?' && mn == nt) {
            s.erase(i, 1);
            s.insert(i, "T");
            nw--;
            nt++;
          }
          if (s[i] == '?' && mn == ng) {
            s.erase(i, 1);
            s.insert(i, "G");
            nw--;
            ng++;
          }
        }
      }
      if (na == nc && nt == nc && nt == ng)
        cout << s << endl;
      else
        cout << "===" << endl;
    }
  }
  return 0;
}
