// Arup Guha
// 4/8/2020
// Solution to COP 4516 Team Final Exam Question: Evil Ninja vs. Tetra-Bot
// Solution is modified from class example, Tetra.

import java.util.*;

public class ninja {

	public static void main(String[] args) {
	
		Scanner stdin = new Scanner(System.in);
		int nC = stdin.nextInt();

		// Process all cases.
		for (int loop=0; loop<nC; loop++) {
		
			// Read in the points.
			vect3D[] plane = new vect3D[3];
			for (int i=0; i<3; i++) {
				int x = stdin.nextInt();
				int y = stdin.nextInt();
				int z = stdin.nextInt();
				plane[i] = new vect3D(x, y, z);
			}
			
			// Get two vectors on the plane.
			vect3D v1 = plane[0].to(plane[1]);
			vect3D v2 = plane[0].to(plane[2]);
			vect3D normal = v1.cross(v2);
			
			// Constant in plane equation.
			int D = normal.dot(plane[0]);
			
			// Each of the four points will contribute -1, 0 or 1 to total.
			// -1 if it's "below" the plane, 0 if on it, and 1 if "above" it.
			// There is no intersection if total is -4 or 4...
			int total = 0;
			
			// Go through all 4 pts.
			for (int i=0; i<4; i++) {
			
				// Make point.
				int x = stdin.nextInt();
				int y = stdin.nextInt();
				int z = stdin.nextInt();
				vect3D pt = new vect3D(x, y, z);
				
				// Find parallel plane with this point.
				int thisD = normal.dot(pt);
				
				// Above plane, add 1.
				if (thisD > D) total++;
				
				// Below plane sub 1.
				else if (thisD < D) total--;
			}
			
			// This is all we have to do!
			if (Math.abs(total) == 4)
				System.out.println("Tetra-Bot Survives!");
			else
				System.out.println("Evil Ninja Prevails!");
		}
	}
}

class vect3D {

	public int x;
	public int y;
	public int z;
	
	public vect3D(int myx, int myy, int myz) {
		x = myx;
		y = myy;
		z = myz;
	}
	
	// Returns this cross other.
	public vect3D cross(vect3D other) {
		int myx = y*other.z - other.y*z;
		int myy = z*other.x - other.z*x;
		int myz = x*other.y - other.x*y;
		return new vect3D(myx, myy, myz);
	}
	
	// Returns this dot other.
	public int dot(vect3D other) {
		return x*other.x + y*other.y + z*other.z;
	}
	
	// Return the vector from pt this to pt other.
	public vect3D to(vect3D other) {
		return new vect3D(other.x-x, other.y-y, other.z-z);
	}
}