#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int test;
  int size;
  cin >> size;
  long long sum = 0;
  vector<double> arr(size), brr(size);
  vector<bool> a(size, false);
  for (int i = 0; i < size; i++) {
    cin >> arr[i];
    brr[i] = ceil(arr[i]);
    sum += brr[i];
    if (brr[i] == arr[i]) a[i] = !a[i];
  }
  for (int i = 0; i < brr.size() && sum != 0; i++) {
    if (a[i]) continue;
    brr[i] -= 1;
    sum--;
  }
  for (int i = 0; i < size; i++) {
    if (brr[i] == 0) brr[i] = 0;
    cout << brr[i] << "\n";
  }
  return 0;
}
