#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 7;
int a[maxn];
int b[maxn];
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  double k;
  long long ans = 0;
  for (int i = 0; i < n; ++i) {
    cin >> k;
    a[i] = (int)floor(k);
    b[i] = (int)ceil(k);
    ans += b[i];
  }
  for (int i = 0; i < n; ++i) {
    if (ans && a[i] != b[i]) {
      ans--;
      printf("%d\n", a[i]);
    } else {
      printf("%d\n", b[i]);
    }
  }
  return 0;
}
