#include <bits/stdc++.h>
using namespace std;
const int inf = 1e9 + 7;
const long long INF = 1e18 + 7;
const int maxn = 2e5 + 7;
int n, a[maxn], mx = 0, id = -1;
int main() {
  ios_base::sync_with_stdio(NULL);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
    if (a[i] >= 0) a[i] = -a[i] - 1;
  }
  if (n % 2 != 0) {
    for (int i = 1; i <= n; i++) {
      if (mx > a[i]) {
        mx = a[i];
        id = i;
      }
    }
    if (mx == -1)
      a[1] = 0;
    else
      a[id] = -a[id] - 1;
  }
  for (int i = 1; i <= n; i++) {
    cout << a[i] << ' ';
  }
  return 0;
}
