#include <iostream>
#include <string>
#include <vector>
#include <queue>
#include <deque>
#include <algorithm>
#include <set>
#include <map>
#include <bitset>
#include <cmath>
#include <functional>
#include <iomanip>
#define vll vector<ll>
#define vvvl vector<vvl>
#define vvl vector<vector<ll>>
#define VV(a, b, c, d) vector<vector<d>>(a, vector<d>(b, c))
#define VVV(a, b, c, d) vector<vvl>(a, vvl(b, vll (c, d)));
#define re(c, b) for(ll c=0;c<b;c++)
#define all(obj) (obj).begin(), (obj).end()
typedef long long int ll;
typedef long double ld;
using namespace std;

vvl G = VV(5001, 0, 0, ll);
// 頂点iを見ている時点でペアが決まっていない点がj個ある場合の数
#define P 1000000007
#define N_MAX 10000000
typedef long long int ll;
ll fac[N_MAX+1];
ll inv[N_MAX+1];
ll finv[N_MAX+1];

ll comb(ll n, ll k){
  if(n<0||k<0||n<k) return 0;
  return (((fac[n]*finv[n-k])%P)*finv[k])%P;
}
ll perm(ll n, ll k){
  if(n<0||k<0||n<k) return 0;
  return (fac[n]*finv[n-k])%P;
}

void init(){
  fac[0] = finv[0] = fac[1] = finv[1] = inv[1] = 1;
  for(int i = 2; i <= N_MAX; i++){
    fac[i] = (fac[i-1]*i)%P;
    inv[i] = ((-(P/i)*inv[P%i])%P+P)%P;
    finv[i] = (finv[i-1]*inv[i])%P;
  }
}
ll pp(ll a, ll b){
  return (a * b)%P;
}

ll root = -1;
vvvl dp(5001, VV(0, 0, 0, ll));
vll pat(10000, 0);

ll dfs(ll now, ll from){
  if(G[now].size()==1){
    vvl tmp = VV(2, 2, 0, ll);
    tmp[1][0] = 1;
    dp[now] = tmp;
    return 1;//ノード数
  }

  ll s = 1, idx = 0;
  vvvl tmp_dp;
  vvl fst = VV(2, 2, 0, ll);
  fst[1][0] = 1;
  tmp_dp.push_back(fst);

  for(auto to:G[now]){
    if(to==from) continue;
    ll num = dfs(to, now);
    tmp_dp.push_back(VV(s+num+1, 2, 0, ll));

    for(int l=0;l<=s;l++){
      for(int r=0;r<=num;r++){
        //rを追加する時に切る場合
        tmp_dp[idx+1][l][1] =
        (tmp_dp[idx+1][l][1] +
        pp(pp(tmp_dp[idx][l][0], dp[to][r][0]), pat[r])+
        pp(pp(tmp_dp[idx][l][1], dp[to][r][1]), pat[r]))%P;

        tmp_dp[idx+1][l][0] =
        (tmp_dp[idx+1][l][0] +
        pp(pp(tmp_dp[idx][l][1], dp[to][r][0]), pat[r])+
        pp(pp(tmp_dp[idx][l][0], dp[to][r][1]), pat[r]))%P;

        //切らない場合
        tmp_dp[idx+1][l+r][0] =
        (tmp_dp[idx+1][l+r][0] +
        pp(tmp_dp[idx][l][0], dp[to][r][0]) +
        pp(tmp_dp[idx][l][1], dp[to][r][1]) )%P;

        tmp_dp[idx+1][l+r][1] =
        (tmp_dp[idx+1][l+r][1] +
        pp(tmp_dp[idx][l][0], dp[to][r][1]) +
        pp(tmp_dp[idx][l][1], dp[to][r][0]) )%P;
      }
    }
    idx++;
    s += num;
  }
  dp[now] = tmp_dp[idx];
  return s;
}


int main(int argc, char const *argv[]) {
  init();
  ll n;std::cin >> n;
  for(int i=0;i<n-1;i++){
    ll a, b;std::cin >> a >> b;
    G[a].push_back(b);
    G[b].push_back(a);
  }
  if(n==2){
    std::cout << 1 << '\n';
    return 0;
  }
  for(int i=1;i<=n;i++){
    if(G[i].size()>1){
      root = i;
      break;
    }
  }
  pat[2] = 1;
  for(ll i=3;i<10000;i++) pat[i] = (pat[i-2]*(i-1))%P;//k個での組
  dfs(root, -1);
  ll ans = 0;
  ll m = dp[root].size();

  for(int i=0;i<m;i++){
    dp[root][i][0] = pp(dp[root][i][0], pat[i])%P;
    dp[root][i][1] = pp(dp[root][i][1], pat[i])%P;
  }
  for(int i=0;i<m;i++){
    ans = (ans + dp[root][i][0])%P;
    ans = (ans - dp[root][i][1] + P)%P;
  }
  std::cout << ans << '\n';
  return 0;
}


Measured memory_bytes: 922864