#include <bits/stdc++.h>
using namespace std;
int main() {
  auto start = chrono::high_resolution_clock::now();
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  long long int t;
  cin >> t;
  while (t--) {
    long long int n;
    cin >> n;
    long long int a[n];
    for (long long int i = 0; i < n; i++) cin >> a[i];
    for (long long int i = 0; i < n; i++) {
      if (i % 2 == 0) {
        if (a[i] <= 0) {
          a[i] = -a[i];
        }
      } else {
        if (a[i] > 0) {
          a[i] = -a[i];
        }
      }
    }
    for (long long int i = 0; i < n; i++) cout << a[i] << " ";
    cout << endl;
  }
  auto finish = chrono::high_resolution_clock::now();
  cerr << "Time elapsed: "
       << (chrono::duration<long double>(finish - start)).count() << "s\n";
  return 0;
}
