#include <bits/stdc++.h>
#pragma GCC optimize(2)
#pragma GCC optimize(3)
#pragma GCC optimize(4)
using namespace std;
const int N = 1e5 + 5;
double a[N];
int n, x[N], y[N];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) scanf("%lf", &a[i]);
  long long tot = 0;
  for (int i = 1; i <= n; ++i) {
    x[i] = floor(a[i]), y[i] = ceil(a[i]);
    tot += x[i];
  }
  tot = abs(tot);
  for (int i = 1; i <= n; ++i) {
    if (x[i] == y[i])
      printf("%d\n", x[i]);
    else {
      if (tot)
        printf("%d\n", y[i]), tot--;
      else
        printf("%d\n", x[i]);
    }
  }
  return 0;
}
