Problem: An undirected graph is given. Each edge of the graph disappears with a constant probability. Calculate the probability with which the remained graph is connected.



Input

The first line contains three integers N (1 \leq N \leq 14), M (0 \leq M \leq 100) and P (0 \leq P \leq 100), separated by a single space. N is the number of the vertices and M is the number of the edges. P is the probability represented by a percentage.

The following M lines describe the edges. Each line contains two integers v_i and u_i (1 \leq u_i, v_i \leq N). (u_i, v_i) indicates the edge that connects the two vertices u_i and v_i.

Output

Output a line containing the probability with which the remained graph is connected. Your program may output an arbitrary number of digits after the decimal point. However, the absolute error should be 10^{-9} or less.

Examples

Input

3 3 50
1 2
2 3
3 1


Output

0.500000000000


Input

3 3 10
1 2
2 3
3 1


Output

0.972000000000


Input

4 5 50
1 2
2 3
3 4
4 1
1 3


Output

0.437500000000

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define rep(i,n) for(int (i)=0;(i)<(int)(n);++(i))
#define all(x) (x).begin(),(x).end()
#define pb push_back
#define fi first
#define se second
#define dbg(x) cout<<#x" = "<<((x))<<endl
template<class T,class U> ostream& operator<<(ostream& o, const pair<T,U> &p){o<<"("<<p.fi<<","<<p.se<<")";return o;}
template<class T> ostream& operator<<(ostream& o, const vector<T> &v){o<<"[";for(T t:v){o<<t<<",";}o<<"]";return o;}


int main(){
    int n,m;
    double p;
    cin >>n >>m >>p;

    vector<int> u(m),v(m);
    rep(i,m){
        cin >>u[i] >>v[i];
        --u[i];
        --v[i];
    }

    p /= 100.0;

    vector<double> pw(m+1);
    pw[0] = 1;
    rep(i,m) pw[i+1] = pw[i]*p;

    vector<double> dp(1<<n);
    rep(mask,1<<n){
        dp[mask] = 1;

        int sub = mask;
        while(1){
            sub = (sub-1)&mask;
            if(sub == 0) break;
            if(sub%2!=1) continue;

            int o_mask = mask^sub;

            int ct = 0;
            rep(i,m){
                if(sub>>u[i]&1){
                    if(o_mask>>v[i]&1) ++ct;
                }
                if(sub>>v[i]&1){
                    if(o_mask>>u[i]&1) ++ct;
                }
            }

            dp[mask] -= dp[sub]*pw[ct];
        }
    }

    cout << fixed << setprecision(15) << dp[(1<<n)-1] << endl;
    return 0;
}