/**
    why I'm too lazy?
**/
#include <bits/stdc++.h>

#define fr first
#define sc second
#define mk make_pair
#define pb push_back
#define pp pop_back
#define ll long long
#define ld long double
#define OK puts("OK");
#define sz(s) (int)s.size()
#define all(s) s.begin(), s.end()

using namespace std;

inline int min(int a, int b)
{
    return (a > b) ? b : a;
}
inline int max(int a, int b)
{
    return (a > b) ? a : b;
}

const int N = 2e5 + 10;
const int inf = 1e9 + 7;
const ll linf = 1e17 + 7;

int n, x, y;
vector <int> g[N];

double dfs(int v, int p, double d)
{
    double ans = 0;
    for(auto to : g[v])
    {
        if(to == p) continue;
        if(v == p)
            ans += dfs(to, v, 1.0 / sz(g[v]) * d);
        else
            ans += dfs(to, v, 1.0 / (sz(g[v]) - 1) * d);
    }
    return ans + d;
}

main()
{
    scanf("%d", &n);
    for(int i = 1; i < n; i++)
        scanf("%d%d", &x, &y), g[x].pb(y), g[y].pb(x);
    for(int i = 1 ; i <= n; i++)
        cout << fixed << setprecision(17) << dfs(i, i, 1.0) - 1.0 << endl;
}
