#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9;
const int N = 1e5;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie();
  int n, x;
  cin >> n;
  vector<pair<int, bool> > lst;
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    cin >> x;
    bool flag = (x < 0) ? true : false;
    if (x < 0) cnt++;
    lst.push_back(make_pair(abs(x), flag));
  }
  sort(lst.begin(), lst.end());
  if (n == 1) {
    int tmp = 1;
    if (lst[0].second) tmp = -1;
    cout << lst[0].first * tmp << endl;
  } else {
    int indi = 1;
    vector<int> ans;
    for (int i = n - 1; i >= 0; i--) {
      if (lst[i].first != 0) {
        if (lst[i].second) {
          if (indi == -1) {
            ans.push_back(lst[i].first * -1);
            indi = 1;
            cnt--;
          } else if (cnt > 1) {
            ans.push_back(lst[i].first * -1);
            indi = -1;
            cnt--;
          }
        } else
          ans.push_back(lst[i].first);
      }
    }
    if (ans.size() == 0)
      cout << "0" << endl;
    else {
      cout << ans[0];
      for (int i = 1; i < ans.size(); i++) {
        cout << " " << ans[i];
      }
      cout << endl;
    }
  }
  return 0;
}
