#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false), cin.tie(NULL);
  int t, n;
  cin >> t;
  while (t--) {
    cin >> n;
    vector<int> a(n);
    for (int i = 1; i <= n; i++) {
      cin >> a[i];
    }
    for (int i = 1; i <= n; i++) {
      if (i % 2 == 1) {
        if (a[i] < 0) {
          a[i] *= -1;
        }
      }
      if (i % 2 == 0) {
        if (a[i] > 0) {
          a[i] *= -1;
        }
      }
    }
    for (int i = 1; i <= n; i++) {
      cout << a[i] << " ";
    }
    cout << endl;
  }
  return 0;
}
