#include <bits/stdc++.h>
using namespace std;
inline long long mod(long long n, long long m) {
  long long ret = n % m;
  if (ret < 0) ret += m;
  return ret;
}
long long gcd(long long a, long long b) { return (b == 0 ? a : gcd(b, a % b)); }
long long lcm(long long a, long long b) { return (a * b) / gcd(a, b); }
long long exp(long long a, long long b, long long m) {
  if (b == 0) return 1;
  if (b == 1) return mod(a, m);
  long long k = mod(exp(a, b / 2, m), m);
  if (b & 1) {
    return mod(a * mod(k * k, m), m);
  } else
    return mod(k * k, m);
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  long long n;
  cin >> n;
  vector<long long> v(n);
  priority_queue<long long> pq;
  for (long long i = 0; i < n; i++) {
    cin >> v[i];
    if (v[i] >= 0) {
      v[i] = -v[i] - 1;
    }
    pq.push(-v[i]);
  }
  long long bs = -pq.top();
  for (long long i = 0; i < n && n % 2; i++) {
    if (v[i] == bs) {
      v[i] = -v[i] - 1;
      break;
    }
  }
  for (long long i = 0; i < n; i++) {
    cout << v[i] << " ";
  }
  cout << "\n";
}
