#include <bits/stdc++.h>
using namespace std;
long long gcd(long long a, long long b) {
  if (!b) return a;
  return gcd(b, a % b);
}
long long power(long long x, long long y, long long p = 1000000007) {
  long long res = 1;
  x %= p;
  while (y > 0) {
    if (y & 1) res = (res * x) % p;
    y = y >> 1;
    x = (x * x) % p;
  }
  return res;
}
long long lcm(long long a, long long b) { return (a * b) / gcd(a, b); }
int32_t main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  srand(chrono::high_resolution_clock::now().time_since_epoch().count());
  long long t = 1;
  while (t--) {
    long long n;
    cin >> n;
    long long a[n];
    for (long long i = 0; i < n; i++) {
      cin >> a[i];
    }
    if (n % 2 == 0) {
      for (long long i = 0; i < n; i++) {
        if (a[i] >= 0) a[i] = -a[i] - 1;
        cout << a[i] << " ";
      }
      cout << "\n";
    } else {
      for (long long i = 0; i < n; i++) {
        if (a[i] >= 0) a[i] = -a[i] - 1;
      }
      long long mx = -2e18, idx = -1;
      for (long long i = 0; i < n; i++) {
        if (abs(a[i]) > mx) {
          mx = abs(a[i]);
          idx = i;
        }
      }
      a[idx] = -a[idx] - 1;
      for (long long i = 0; i < n; i++) {
        cout << a[i] << " ";
      }
      cout << "\n";
    }
  }
  return 0;
}
