#include <bits/stdc++.h>
using namespace std;
const int N = 202, MOD = 1e9 + 7;
int n, f[N], dp[N][N][N];
string s;
int failure(char c, int l) {
  if (l >= s.size()) return l;
  while (l > 0 && c != s[l]) l = f[l - 1];
  return l + (c == s[l]);
}
void KMP() {
  for (int i = 1; s[i]; i++) f[i] = failure(s[i], f[i - 1]);
}
int solve(int rem = 2 * n, int cnt = 0, int len = 0) {
  if (cnt < 0 || cnt > rem) return 0;
  if (rem == 0) return (cnt == 0 && len == s.size());
  int& ret = dp[rem][cnt][len];
  if (~ret) return ret;
  ret = 0;
  ret += solve(rem - 1, cnt + 1, failure('(', len));
  ret += solve(rem - 1, cnt - 1, failure(')', len));
  return ret %= MOD;
}
int main() {
  cin >> n >> s;
  KMP();
  memset(dp, -1, sizeof(dp));
  cout << solve() << endl;
  return 0;
}
