#include <bits/stdc++.h>
#include <unordered_set>

#define f(i, a, b) for (int i = a; i < b; i++)
#define rf(i, a, b) for (int i = a; i > b; i--)
#define lf(i, a, b) for (long long i = a; i < b; i++)
#define sq(a) (a)*(a)
#define cube(a) (a)*(a)*(a)
#define pb push_back
#define ppb pop_back
#define LB lower_bound
#define UB upper_bound
#define sarr(arr, n) sort(arr, arr + n);
#define svec(v) sort(v.begin(), v.end());
#define svecr(v) sort(v.rbegin(), v.rend());
#define intinp(var) int var; \
        cin >> var;
#define adjc(adj, n) int adj[n];
#define adjcw(adj, n) vector<pair<int, int>> adj[n];
#define PYES cout << "YES\n"
#define PNO cout << "NO\n"
#define PYes cout << "Yes\n"
#define PNo cout << "No\n"
#define endl "\n"

using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef vector<pair<int, int>> vii;
typedef vector<string> vs;
typedef unordered_map<int, int> um;

int main(){
    ll n, k; cin >> n >> k;
    f(i, 0, k){
        if (n%200 == 0) n /= 200;
        else{
            n *= 1000;
            n += 200;
        }
    }
    cout << n << "\n";
    return 0;
}

//
//                       _oo0oo_
//                      o8888888o
//                      88" . "88
//                      (| -_- |)
//                      0\  =  /0
//                    ___/`---'\___
//                  .' \\|     |// '.
//                 / \\|||  :  |||// \
//                / _||||| -:- |||||- \
//               |   | \\\  -  /// |   |
//               | \_|  ''\---/''  |_/ |
//               \  .-\__  '-'  ___/-. /
//             ___'. .'  /--.--\  `. .'___
//          ."" '<  `.___\_<|>_/___.' >' "".
//         | | :  `- \`.;`\ _ /`;.`/ - ` : | |
//         \  \ `_.   \_ __\ /__ _/   .-` /  /
//     =====`-.____`.___ \_____/___.-`___.-'=====
//                       `=---='

#pragma GCC optimize("Ofast")
#include<bits/stdc++.h>
#define ll long long
#define gmax(x,y) x=max(x,y)
#define gmin(x,y) x=min(x,y)
#define F first
#define S second
#define P pair
#define FOR(i,a,b) for(int i=a;i<=b;i++)
#define rep(i,a,b) for(int i=a;i<b;i++)
#define V vector
#define RE return
#define ALL(a) a.begin(),a.end()
#define MP make_pair
#define PB emplace_back
#define PF emplace_front
#define FILL(a,b) memset(a,b,sizeof(a))
#define lwb lower_bound
#define upb upper_bound
#define lc (x<<1)
#define rc ((x<<1)|1)
using namespace std;
P<int,int> p[400005];
int f[400005],L[400005],R[400005];
int ans[400005],a[400005];
int n;
bool check(int x,int y){
	RE x>=1&&x<=n&&y>=1&&y<=n&&f[x]!=f[y];
}
void erase(int x){
	R[L[x]]=R[x];
	L[R[x]]=L[x];
}
signed main(){
	ios::sync_with_stdio(0);
	cin.tie(0);
	cin>>n;
	n*=2;
	FOR(i,1,n)cin>>p[i].F,p[i].S=i;
	sort(p+1,p+n+1);
	set<int> s;
	FOR(i,1,n/2)f[p[i].S]=1;
	FOR(i,1,n)L[i]=i-1,R[i]=i+1;
	rep(i,1,n){
		if(f[i]!=f[i+1])s.emplace(i);
	} 
	while(!s.empty()){
		int t=*s.begin();
		ans[t]=1;
		ans[R[t]]=2;
		s.erase(s.begin());
		if(check(L[t],t))s.erase(L[t]);
		if(check(R[t],R[R[t]]))s.erase(R[t]);
		if(check(L[t],R[R[t]]))s.emplace(L[t]);
		erase(R[t]);
		erase(t);
	}
	FOR(i,1,n)cout<<(ans[i]==1?'(':')');
	RE 0;
}
