#include <bits/stdc++.h>
using namespace std;
const int maxn = 100010;
long long gcd(long long x, long long y) {
  if (y == 0) return x;
  return gcd(y, x % y);
}
int main() {
  int T = 1;
  while (T--) {
    long long n;
    cin >> n;
    vector<int> v(n), ch(n);
    for (long long i = 0; i < n; i++) {
      long double k;
      cin >> k;
      if (k - (long long)k == 0) {
        ch[i]++;
        v[i] = (long long)k;
      } else
        v[i] = (k >= 0 ? (long long)k : (long long)k - 1);
    }
    long long sum = 0;
    for (long long i = 0; i < n; i++) sum -= v[i];
    for (long long i = 0; i < n; i++) {
      if (!sum) break;
      if (!ch[i]) {
        v[i]++;
        sum--;
      }
    }
    for (long long i = 0; i < n; i++) cout << v[i] << endl;
  }
  return 0;
}
