Problem: Try guessing the statement from this picture: 

<image>

You are given a non-negative integer d. You have to find two non-negative real numbers a and b such that a + b = d and a ⋅ b = d.

Input

The first line contains t (1 ≤ t ≤ 10^3) — the number of test cases.

Each test case contains one integer d (0 ≤ d ≤ 10^3).

Output

For each test print one line.

If there is an answer for the i-th test, print "Y", and then the numbers a and b.

If there is no answer for the i-th test, print "N".

Your answer will be considered correct if |(a + b) - a ⋅ b| ≤ 10^{-6} and |(a + b) - d| ≤ 10^{-6}.

Example

Input


7
69
0
1
4
5
999
1000


Output


Y 67.985071301 1.014928699
Y 0.000000000 0.000000000
N
Y 2.000000000 2.000000000
Y 3.618033989 1.381966011
Y 997.998996990 1.001003010
Y 998.998997995 1.001002005

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int read() {
  int x = 0, f = 1;
  char c = getchar();
  for (; !isdigit(c); c = getchar())
    if (c == '-') f = -1;
  for (; isdigit(c); c = getchar()) x = x * 10 + c - '0';
  return x * f;
}
namespace Sa {
struct Node {
  double x, y;
  Node() {}
  Node(double x, double y) : x(x), y(y) {}
  Node operator-(Node a) const { return Node(x - a.x, y - a.y); }
  double operator*(Node a) const { return x * a.y - y * a.x; }
} a[1], b[1];
double l, r, Mid, Ans, Now, x, y, Ax, T, N2;
int i, j, k, n, m;
inline double Getrand() { return rand() % 1000 / 1000.0; }
inline double Gety(double x) {
  for (int i = 1; i < n; i++)
    if (a[i + 1].x > x)
      return (a[i + 1].y - a[i].y) / (a[i + 1].x - a[i].x) * (x - a[i].x) +
             a[i].y;
}
inline bool Check(Node A) {
  for (int i = 1; i < n; i++)
    if ((A - a[i]) * (A - a[i + 1]) < 0) return 0;
  return 1;
}
inline double Calc(double x) {
  double l = 0, r = 0, Mid;
  while (r - l > 1) {
    Mid = (l + r) / 2.0;
    if (Check(Node(x, Mid)))
      r = Mid;
    else
      l = Mid;
  }
  l -= Gety(x);
  if (l < Ans) Ans = l, Ax = x;
  return l;
}
inline void SA(double T) {
  for (; T > 0.00001; T *= 0.99) {
    y = x + T * (Getrand() * 2 - 1);
    if (y < a[1].x || y > a[n].x) continue;
    N2 = Calc(x) - Calc(y);
    if (N2 > 0 || exp(N2 / T) > Getrand()) x = y;
  }
  for (int i = 1; i <= 1000; i++) {
    y = Ax + T * (Getrand() * 2 - 1);
    if (y < a[1].x || y > a[n].x) continue;
    Calc(y);
  }
}
}  // namespace Sa
int main() {
  int t = read();
  while (t--) {
    int n = read();
    double T = n;
    if (n * n < 4 * n) {
      printf("N\n");
      continue;
    }
    double a = (T + sqrt(T * T - 4.0 * T)) / 2.0;
    double b = (T - sqrt(T * T - 4.0 * T)) / 2.0;
    printf("Y %.10f %.10f\n", a, b);
  }
}