import java.util.*; import java.io.*; import static java.util.Arrays.*; import static java.lang.Math.*; public class No0202 { static final Reader in = new Reader(); static final PrintWriter out = new PrintWriter(System.out,false); static void solve(){ int n = in.nextInt(); f = new boolean[20001][20001]; int cnt = 0; for (int i=0; i