#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long int n;
  cin >> n;
  string a;
  cin >> a;
  long long int na = 0, nc = 0, ng = 0, nt = 0, nq = 0, c = 0, sum = 0,
                m = INT_MIN;
  if (n % 4 != 0)
    cout << "===" << endl;
  else {
    for (long long int i = 0; i < n; i++) {
      if (a[i] == 'A')
        na++;
      else if (a[i] == 'C')
        nc++;
      else if (a[i] == 'G')
        ng++;
      else if (a[i] == 'T')
        nt++;
      else if (a[i] == '?')
        nq++;
    }
    m = max(na, max(nc, max(ng, nt)));
    sum = (m - na) + (m - nc) + (m - ng) + (m - nt);
    if (nq == 0 && na == nc && nc == ng && ng == nt)
      cout << a << endl;
    else if (nq == sum) {
      for (long long int i = 0; i < n; i++) {
        if (a[i] == '?') {
          if (na < m) {
            a[i] = 'A';
            na++;
          } else if (nc < m) {
            a[i] = 'C';
            nc++;
          } else if (ng < m) {
            a[i] = 'G';
            ng++;
          } else if (nt < m) {
            a[i] = 'T';
            nt++;
          }
        }
      }
      cout << a << endl;
    } else if (nq > sum && (nq - sum) % 4 == 0) {
      for (long long int i = 0; i < n; i++) {
        if (a[i] == '?') {
          if (na < m) {
            a[i] = 'A';
            na++;
            nq--;
          } else if (nc < m) {
            a[i] = 'C';
            nc++;
            nq--;
          } else if (ng < m) {
            a[i] = 'G';
            ng++;
            nq--;
          } else if (nt < m) {
            a[i] = 'T';
            nt++;
            nq--;
          }
        }
      }
      for (long long int i = 0; i < n; i++) {
        if (a[i] == '?') {
          if (c == 0) {
            a[i] = 'A';
            c++;
          } else if (c == 1) {
            a[i] = 'G';
            c++;
          } else if (c == 2) {
            a[i] = 'C';
            c++;
          } else if (c == 3) {
            a[i] = 'T';
            c = 0;
          }
        }
      }
      cout << a << endl;
    } else if (nq == n) {
      for (long long int i = 0; i < n; i++) {
        if (a[i] == '?') {
          if (c == 0) {
            a[i] = 'A';
            c++;
          } else if (c == 1) {
            a[i] = 'G';
            c++;
          } else if (c == 2) {
            a[i] = 'C';
            c++;
          } else if (c == 3) {
            a[i] = 'T';
            c = 0;
          }
        }
      }
      cout << a << endl;
    } else
      cout << "===" << endl;
  }
}
void testcase() {
  int t;
  cin >> t;
  while (t--) {
    solve();
  }
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  solve();
}
