Under construction

Still being built. Things may change

Game

Time limit2sMemory limit256 MB

Summary
If the start is within Manhattan distance m of the finish, First wins on move 1; otherwise both players can avoid losing forever, so the result is Infinity.
Level

Easy3 of 10

Topics
Game theory, Math, Implementation
Solved
No attempts yet

Problem

Jury members of Russian Code Cup sometimes play various games in their free time.

For example, between the last two rounds, the jury came up with a new game with the following rules:

  • Initially, a piece is at point (xs,ys)(x_s, y_s) on an infinite field.
  • In one move, a player can move the piece from (x1,y1)(x_1, y_1) to any cell (x2,y2)(x_2, y_2) such that ∣x1−x2∣+∣y1−y2∣≤m|x_1 - x_2| + |y_1 - y_2| \le m.
  • Two players play the game, taking turns.
  • The player who places the piece on (xf,yf)(x_f, y_f) wins.

You are given nn descriptions of games. Each description has five numbers: the move limit mm, and the starting and final positions of the piece.

For each game, determine who wins under optimal play and on which move. Neither player wants to lose, so the players may play indefinitely.

Input

The first line contains one integer nn (1≤n≤1001 \le n \le 100), the number of games. The next nn lines each contain five integers mm, xsx_s, ysy_s, xfx_f, yfy_f (all numbers are in the range from 1 to 1000), the move limit and the starting and final coordinates of the piece. The starting and final points are always different.

Output

For each game, print one line. Print "First" if the first player wins, "Second" if the second player wins, and "Infinity" if the players play indefinitely. If the game is finite, also print the number of the move after which the game ends, separated from the result by a space.

Examples1

  1. Example 1

    Input
    2
    2 3 1 3 2
    2 3 1 1 4
    
    Expected output
    First 1
    Infinity