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
import java.io.IOException;
import java.io.InputStream;
import java.math.BigInteger;
import java.util.*;
public class Main
{
   static double sqrtt(long n, long prec) 
  { 
    long start=0,end=n,mid; 
 
     
    double ans=0.0; 
 
    while (start <= end) { 
        mid = (start + end) / 2; 
        if (mid * mid == n) { 
            ans = mid; 
            break; 
        } 
 
        if (mid * mid < n) { 
            start = mid + 1; 
            ans = mid; 
        } 
 
        else { 
            end = mid - 1; 
        } 
    } 
 
    double inc= 0.1; 
    for (long i=0;i<prec;i++) { 
        while (ans*ans<=n) { 
            ans+=inc; 
        } 
        ans=ans-inc; 
        inc=inc/10; 
    } 
    return ans; 
} 
    public static void main(String[] args)throws IOException
    {
        Scanner in=new Scanner(System.in);
        StringBuffer st=new StringBuffer();
        int t=in.nextInt();
        double n=0,a=0,b=0,w;
        for(int i=0;i<t;i++){
          n=in.nextDouble();
        if(n<4&&n>0)
	   	{
		  	st.append("N\n");
			  continue;
		  }
		  st.append("Y ");
	  	w=sqrtt((long)((n*n)-(4*n)),10);
	  	a=n+w;
	  	a=a/2;
	  	b=n-w;
	  	b=b/2;
      String x=String.format("%.9f",a);
      String y=String.format("%.9f",b);
      st.append(x+" "+y+"\n");
     }
          
         
        System.out.print(st);
    }
    static class FastReader{
 
        byte[] buf = new byte[2048];
        int index, total;
        InputStream in;
 
        FastReader(InputStream is) {
            in = is;
        }
 
        int scan() throws IOException {
            if (index >= total) {
                index = 0;
                total = in.read(buf);
                if (total <= 0) {
                    return -1;
                }
            }
            return buf[index++];
        }
 
        String next() throws IOException {
            int c;
            for (c = scan(); c <= 32; c = scan());
            StringBuilder sb = new StringBuilder();
            for (; c > 32; c = scan()) {
                sb.append((char) c);
            }
            return sb.toString();
        }
 
        int nextInt() throws IOException {
            int c, val = 0;
            for (c = scan(); c <= 32; c = scan());
            boolean neg = c == '-';
            if (c == '-' || c == '+') {
                c = scan();
            }
            for (; c >= '0' && c <= '9'; c = scan()) {
                val = (val << 3) + (val << 1) + (c & 15);
            }
            return neg ? -val : val;
        }
 
        long nextLong() throws IOException {
            int c;
            long val = 0;
            for (c = scan(); c <= 32; c = scan());
            boolean neg = c == '-';
            if (c == '-' || c == '+') {
                c = scan();
            }
            for (; c >= '0' && c <= '9'; c = scan()) {
                val = (val << 3) + (val << 1) + (c & 15);
            }
            return neg ? -val : val;
        }
    }
}      