func_code_string: #include <bits/stdc++.h>   long long mod(long long x) {     if (x < 0) return -x;     return x;   }   long long expo(long long x, long long y) {     long long res = 1;     while (y > 0) {       if (y % 2 == 1) res = (res * x);       y = y >> 1;       x = x * x;     }     return res;   }   using namespace std;   const int MAXN = 500005;   vector<long long> v;   long long a[1000000], b[1000000];   int main() {     ios_base::sync_with_stdio(false);     long long n, t, m, k, x, y;     cin >> n;     string s;     cin >> s;     x = 0;     y = 0;     t = 0;     if (n % 2 != 0) {       cout <<  :( ;       return 0;     }     for (long long i = 0; i < n; i++) {       if (s[i] ==  ) ) {         y++;       }       if (s[i] ==  ( ) {         x++;       }     }     k = n / 2 - x;     for (long long i = 0; i < n; i++) {       if (s[i] ==  ? ) {         s[i] =  ( ;         k--;       }       if (k <= 0) break;     }     k = n / 2 - y;     for (long long i = 0; i < n; i++) {       if (s[i] ==  ? ) {         s[i] =  ) ;         k--;       }       if (k <= 0) break;     }     t = 0;     for (long long i = 0; i < n; i++) {       if (s[i] ==  ) ) {         t--;       }       if (s[i] ==  ( ) {         t++;       }       if (t <= 0 && i != n - 1) {         cout <<  :( ;         return 0;       }       if (t < 0) {         cout <<  :( ;         return 0;       }     }     if (t != 0) {       cout <<  :( ;       return 0;     }     cout << s;     return 0;   }   