#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int a[n];
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++) {
    if (a[i] >= 0) a[i] = -a[i] - 1;
  }
  if (n % 2 != 0) {
    int index = -1, key = INT_MAX;
    for (int i = 0; i < n; i++) {
      if (a[i] != -1 && a[i] < key) {
        key = a[i];
        index = i;
      }
    }
    if (index != -1)
      a[index] = -a[index] - 1;
    else
      a[0] = 0;
  }
  for (int i = 0; i < n; i++) cout << a[i] << " ";
  cout << endl;
}
