You're given the centers of three equal sides of a strictly convex tetragon. Your task is to restore the initial tetragon.

Input

The first input line contains one number T — amount of tests (1 ≤ T ≤ 5·104). Each of the following T lines contains numbers x1, y1, x2, y2, x3, y3 — coordinates of different points that are the centers of three equal sides (non-negative integer numbers, not exceeding 10).

Output

For each test output two lines. If the required tetragon exists, output in the first line YES, in the second line — four pairs of numbers — coordinates of the polygon's vertices in clockwise or counter-clockwise order. Don't forget, please, that the tetragon should be strictly convex, i.e. no 3 of its points lie on one line. Output numbers with 9 characters after a decimal point.

If the required tetragon doen't exist, output NO in the first line, and leave the second line empty.

Examples

Input

3
1 1 2 2 3 3
0 1 1 0 2 2
9 3 7 9 9 8


Output

NO

YES
3.5 1.5 0.5 2.5 -0.5 -0.5 2.5 0.5
NO
#include <bits/stdc++.h>
using namespace std;
int t;
pair<double, double> p[3];
double product(pair<double, double> O, pair<double, double> A,
               pair<double, double> B) {
  return (A.first - O.first) * (B.second - O.second) -
         (B.first - O.first) * (A.second - O.second);
}
pair<double, double> reflect(pair<double, double> O, pair<double, double> A) {
  return pair<double, double>(2 * O.first - A.first, 2 * O.second - A.second);
}
pair<double, double> center(pair<double, double> A, pair<double, double> B,
                            pair<double, double> C) {
  double D =
      2 * (A.first * (B.second - C.second) + B.first * (C.second - A.second) +
           C.first * (A.second - B.second));
  double OX =
      ((A.second * A.second + A.first * A.first) * (B.second - C.second) +
       (B.second * B.second + B.first * B.first) * (C.second - A.second) +
       (C.second * C.second + C.first * C.first) * (A.second - B.second)) /
      D;
  double OY =
      ((A.second * A.second + A.first * A.first) * (C.first - B.first) +
       (B.second * B.second + B.first * B.first) * (A.first - C.first) +
       (C.second * C.second + C.first * C.first) * (B.first - A.first)) /
      D;
  return pair<double, double>(OX, OY);
}
vector<pair<double, double> > solve(pair<double, double> A,
                                    pair<double, double> B,
                                    pair<double, double> C) {
  vector<pair<double, double> > tmp;
  tmp.clear();
  if (fabs(product(reflect(A, B), A, C)) <= 1e-7) return tmp;
  tmp.push_back(center(reflect(A, B), A, C));
  if (fabs(product(reflect(A, C), A, B)) <= 1e-7) return tmp;
  tmp.push_back(center(reflect(A, C), A, B));
  tmp.push_back(reflect(B, tmp[1]));
  tmp.push_back(reflect(C, tmp[0]));
  return tmp;
}
bool check(vector<pair<double, double> > p) {
  if (p.size() != 4) return false;
  for (int i = 0; i != 4; ++i)
    if (product(p[i], p[(i + 1) % 4], p[(i + 2) % 4]) *
            product(p[i], p[(i + 1) % 4], p[(i + 3) % 4]) <=
        1e-7)
      return false;
  return true;
}
int main() {
  for (scanf("%d", &t); t; --t) {
    for (int i = 0; i != 3; ++i) scanf("%lf%lf", &p[i].first, &p[i].second);
    bool flag = false;
    for (int i = 0; i != 3; ++i) {
      vector<pair<double, double> > tmp =
          solve(p[i], p[(i + 1) % 3], p[(i + 2) % 3]);
      if (check(tmp)) {
        printf("YES\n");
        for (vector<pair<double, double> >::iterator iter = tmp.begin();
             iter != tmp.end(); ++iter)
          printf("%.10f %.10f ", iter->first, iter->second);
        printf("\n");
        flag = true;
        break;
      }
    }
    if (!flag) printf("NO\n\n");
  }
  return 0;
}
