#include <bits/stdc++.h>
using namespace std;
#pragma comment(linker, "/STACK:255000000")
bool firstout = 1;
template <class T>
T &minn(T &a, T b) {
  if (b < a) a = b;
  return a;
}
template <class T>
T &maxx(T &a, T b) {
  if (a < b) a = b;
  return a;
}
int &madd(int &a, int b) {
  a += b;
  if (a >= 1000000009) a -= 1000000009;
  return a;
}
int &msub(int &a, int b) {
  a -= b;
  if (a < 0) a += 1000000009;
  return a;
}
int &mmult(int &a, int b) { return a = (long long)a * b % 1000000009; }
int mdiv(long long a, long long b, long long m) {
  a = (a % m + m) % m;
  b = (b % m + m) % m;
  if (a % b == 0) return a / b;
  return (a + m * mdiv(-a, m, b)) / b;
}
int n, m;
int A[1012];
bool fnd(long long a, long long b) {
  if (a > b) swap(a, b);
  if (a == 0) return 0;
  bool res = fnd(b % a, a);
  if (!res) return 1;
  b = b / a;
  b %= a + 1;
  return (b & 1) == 0;
}
int main() {
  int i, j, k;
  char c;
  long long a, b, d;
  int ts;
  int tss;
  scanf(
      "%"
      "d",
      &(tss));
  for (ts = (1); ts < (tss + 1); ++ts) {
    scanf(
        "%"
        "I64d",
        &(a));
    scanf(
        "%"
        "I64d",
        &(b));
    int res = fnd(a, b);
    if (res)
      printf(
          "%"
          "s",
          ("First"));
    else
      printf(
          "%"
          "s",
          ("Second"));
    printf("\n"), firstout = 1;
  }
  return 0;
}
