#include <bits/stdc++.h>
#pragma GCC target("popcnt")
using namespace std;
using ll = long long;
void solve() {
  int n;
  cin >> n;
  ll arr[n];
  for (int i = 0; i < n; i++) cin >> arr[i];
  for (int i = 0; i < n; i++) {
    if (i & 1) {
      if (abs(arr[i]) != arr[i]) arr[i] = -arr[i];
    } else {
      if (abs(arr[i]) == arr[i]) arr[i] = -arr[i];
    }
  }
  for (ll& k : arr) cout << k << " ";
  cout << "\n";
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int t;
  cin >> t;
  while (t--) solve();
  return 0;
}
