#include <algorithm>
#include <bitset>
#include <cassert>
#include <chrono>
#include <climits>
#include <cmath>
#include <complex>
#include <cstring>
#include <deque>
#include <functional>
#include <iostream>
#include <iomanip>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#include <cstdint>
using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef pair<int,int> pii;
#define MP make_pair
#define PB push_back
#define inf 1000000007
#define rep(i,n) for(int i = 0; i < (int)(n); ++i)
#define all(x) (x).begin(),(x).end()

template<typename A, size_t N, typename T>
void Fill(A (&array)[N], const T &val){
    std::fill( (T*)array, (T*)(array+N), val );
}
 
template<class T> inline bool chmax(T &a, T b){
    if(a<b){
        a = b;
        return true;
    }
    return false;
}

template<class T> inline bool chmin(T &a, T b){
    if(a>b){
        a = b;
        return true;
    }
    return false;
}

template <unsigned int mod>
class ModInt {
private:
    unsigned int v;
    static unsigned int norm(const unsigned int& x){ return x < mod ? x : x - mod; }
    static ModInt make(const unsigned int& x){ ModInt m; return m.v = x, m; }
    static ModInt inv(const ModInt& x){ return make(inverse(x.v, mod)); }
    static unsigned int inverse(int a, int m){
        int u[] = {a, 1, 0}, v[] = {m, 0, 1}, t;
        while(*v){
            t = *u / *v;
            swap(u[0] -= t * v[0], v[0]), swap(u[1] -= t * v[1], v[1]), swap(u[2] -= t * v[2], v[2]);
        }
        return (u[1] % m + m) % m;
    }

public:
    ModInt() : v{0}{}
    ModInt(const long long val) : v{norm(val % mod + mod)} {}
    ModInt(const ModInt<mod>& n) : v{n()} {}
    explicit operator bool() const noexcept { return v != 0; }
    bool operator!() const noexcept { return !static_cast<bool>(*this); }
    ModInt& operator=(const ModInt& n){ return v = n(), (*this); }
    ModInt& operator=(const long long val){ return v = norm(val % mod + mod), (*this); }
    ModInt operator+() const { return *this; }
    ModInt operator-() const { return v == 0 ? make(0) : make(mod - v); }
    ModInt operator+(const ModInt& val) const { return make(norm(v + val())); }
    ModInt operator-(const ModInt& val) const { return make(norm(v + mod - val())); }
    ModInt operator*(const ModInt& val) const { return make((long long)v * val() % mod); }
    ModInt operator/(const ModInt& val) const { return *this * inv(val); }
    ModInt& operator+=(const ModInt& val){ return *this = *this + val; }
    ModInt& operator-=(const ModInt& val){ return *this = *this - val; }
    ModInt& operator*=(const ModInt& val){ return *this = *this * val; }
    ModInt& operator/=(const ModInt& val){ return *this = *this / val; }
    ModInt operator+(const long long val) const { return ModInt{v + val}; }
    ModInt operator-(const long long val) const { return ModInt{v - val}; }
    ModInt operator*(const long long val) const { return ModInt{(long long)v * (val % mod)}; }
    ModInt operator/(const long long val) const { return ModInt{(long long)v * inv(val)}; }
    ModInt& operator+=(const long long val){ return *this = *this + val; }
    ModInt& operator-=(const long long val){ return *this = *this - val; }
    ModInt& operator*=(const long long val){ return *this = *this * val; }
    ModInt& operator/=(const long long val){ return *this = *this / val; }
    bool operator==(const ModInt& val) const { return v == val.v; }
    bool operator!=(const ModInt& val) const { return !(*this == val); }
    bool operator==(const long long val) const { return v == norm(val % mod + mod); }
    bool operator!=(const long long val) const { return !(*this == val); }
    unsigned int operator()() const { return v; }
    friend ModInt operator+(const long long val, const ModInt& n) { return n + val; }
    friend ModInt operator-(const long long val, const ModInt& n) { return ModInt{val - n()}; }
    friend ModInt operator*(const long long val, const ModInt& n) { return n * val; }
    friend ModInt operator/(const long long val, const ModInt& n) { return ModInt{val} / n; }
    friend bool operator==(const long long val, const ModInt& n) { return n == val; }
    friend bool operator!=(const long long val, const ModInt& n) { return !(val == n); }
    friend istream& operator>>(istream& is, ModInt& n){
        unsigned int v;
        return is >> v, n = v, is;
    }
    friend ostream& operator<<(ostream& os, const ModInt& n){ return (os << n()); }
    friend ModInt mod_pow(ModInt x, long long n){
        ModInt ans = 1;
        while(n){
            if(n & 1) ans *= x;
            x *= x, n >>= 1;
        }
        return ans;
    }
};

#define MOD 1000000007
using mod = ModInt<MOD>;

#define MAX_N 10000
mod inv[MAX_N],fac[MAX_N],finv[MAX_N];
mod two[MAX_N];
void make()
{
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for(int i=2;i<MAX_N;i++){
        inv[i] = MOD - inv[MOD % i] * (MOD / i);
        fac[i] = fac[i-1] * i;
        finv[i] = finv[i-1] * inv[i];
    }
    two[0] = 1;
    for(int i=1;i<MAX_N;i++){
        two[i] = (mod)1/(mod_pow((mod)2,i));
    }
}

mod comb(int a, int b)
{
    if(a<b) return 0;
    return fac[a] * finv[b] * finv[a-b];
}
int n;
vector<vector<int> > g;
vector<int> c;
vector<vector<mod> > dfs(int id,int pre){
    vector<vector<mod> > res(c[id]+1,vector<mod>(2));
    bool flag = 1;
    int cc = 0;
    for(auto x:g[id]){
        if(x!=pre){
            auto p = dfs(x,id);
            if(flag){
                flag = 0;
                res = p;
                vector<mod>qq(2);
                res.push_back(qq);
                int m = p.size();
                rep(j,2){
                    rep(i,m){
                        
                        if(i%2==0){
                            res[0][1-j] += p[i][j]*fac[i]*finv[i/2]*two[i/2];
                        }
                    }
                }
            }else{
                int m = p.size();
                vector<vector<mod> > tmp(cc+m+1,vector<mod>(2)); 
                rep(i,m){
                    rep(k,cc+1){
                        tmp[i+k][0] += res[k][0]*p[i][0] + res[k][1]* p[i][1];
                        tmp[i+k][1] += res[k][1]*p[i][0] + res[k][0]* p[i][1];
                        if(i%2==0){
                            tmp[k][0] += (res[k][0]*p[i][1]+res[k][1]*p[i][0])*fac[i]*finv[i/2]*two[i/2];
                            tmp[k][1] += (res[k][0]*p[i][0]+res[k][1]*p[i][1])*fac[i]*finv[i/2]*two[i/2];
                        }
                    }
                }
                res = tmp;
            }
            cc += c[x];
            
        }
    }
    if(flag){
        res[1][0] = 1;
        return res;
    }
    rep(j,2){
        for(int i=c[id];i>=1;i--){
            res[i][j] = res[i-1][j];
        }
    }
    return res;
}

int init(int id,int pre){
    for(auto x:g[id]){
        if(x!=pre){
            c[id] += init(x,id);
        }
    }
    c[id]++;
    return c[id];
}

int main(){
    make();
    cin >> n;
    g.resize(n);
    c.resize(n);
    rep(i,n-1){
        int a,b;
        cin >> a >> b;
        a--;b--;
        g[a].push_back(b);
        g[b].push_back(a);
    }
    init(0,-1);
    vector<vector<mod> > res = dfs(0,-1);
    mod ans = 0;
    for(int i=0;i<=n;i++){
        ans += (res[i][0] - res[i][1])*fac[i]*finv[i/2]*two[i/2];
    }
    cout << ans << endl;
    return 0;
}

Measured memory_bytes: 457216