#include <bits/stdc++.h>
using namespace std;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long n, sum = 0;
  vector<long long> mas, change;
  cin >> n;
  mas.resize(n);
  change.resize(n);
  for (long long i = 0; i < n; i++) {
    float x;
    cin >> x;
    if (x < 0)
      mas[i] = (long long)x;
    else
      mas[i] = ceil(x);
    change[i] = (x != (long long)x);
    sum += mas[i];
  }
  for (long long i = 0; i < n; i++) {
    if (sum && change[i]) {
      mas[i]--;
      sum--;
    }
    cout << mas[i] << "\n";
  }
  return 0;
}
