#include <bits/stdc++.h>
using ll = long long;
const int maxn = 5e5 + 27;
const ll mod = 998244353;
int n, u, v;
ll f[maxn][2], g[maxn][2];
std::vector<int> ch[maxn];
void dfs(int u, int fa) {
  g[u][0] = 1;
  for (int v : ch[u]) {
    if (v == fa) continue;
    dfs(v, u);
    ll f0 = f[u][0], f1 = f[u][1], g0 = g[u][0], g1 = g[u][1];
    g[u][0] = (g0 * g[v][1] + g0 * (g[v][0] + g[v][1])) % mod;
    g[u][1] = (g1 * 2 * (g[v][0] + g[v][1]) + g0 * g[v][0]) % mod;
    f[u][0] = (g0 * (f[v][0] + f[v][1]) + f0 * (g[v][0] + g[v][1]) +
               g0 * f[v][1] + f0 * g[v][1]) %
              mod;
    f[u][1] = (f1 * 2 * (g[v][0] + g[v][1]) + g1 * 2 * (f[v][0] + f[v][1]) +
               f0 * g[v][0] + g0 * f[v][0] + g[v][0] * g0) %
              mod;
  }
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i < n; ++i) {
    scanf("%d%d", &u, &v);
    ch[u].push_back(v);
    ch[v].push_back(u);
  }
  dfs(1, 0);
  printf("%lld", 2ll * (f[1][0] + f[1][1]) % mod);
  return 0;
}
