Problem: Two players play the following game. Initially, the players have a knife and a rectangular sheet of paper, divided into equal square grid cells of unit size. The players make moves in turn, the player who can't make a move loses. In one move, a player can take the knife and cut the paper along any segment of the grid line (not necessarily from border to border). The part of the paper, that touches the knife at least once, is considered cut. There is one limit not to turn the game into an infinite cycle: each move has to cut the paper, that is the knife has to touch the part of the paper that is not cut before.

Obviously, the game ends when the entire sheet is cut into 1 × 1 blocks. During the game, the pieces of the sheet are not allowed to move. It is also prohibited to cut along the border. The coordinates of the ends of each cut must be integers.

You are given an n × m piece of paper, somebody has already made k cuts there. Your task is to determine who will win if the players start to play on this sheet. You can consider that both players play optimally well. If the first player wins, you also need to find the winning first move.

Input

The first line contains three integers n, m, k (1 ≤ n, m ≤ 109, 0 ≤ k ≤ 105) — the sizes of the piece of paper and the number of cuts. Then follow k lines, each containing 4 integers xbi, ybi, xei, yei (0 ≤ xbi, xei ≤ n, 0 ≤ ybi, yei ≤ m) — the coordinates of the ends of the existing cuts. 

It is guaranteed that each cut has a non-zero length, is either vertical or horizontal and doesn't go along the sheet border.

The cuts may intersect, overlap and even be the same. That is, it is not guaranteed that the cuts were obtained during any correct game.

Output

If the second player wins, print "SECOND". Otherwise, in the first line print "FIRST", and in the second line print any winning move of the first player (the coordinates of the cut ends, follow input format to print them).

Examples

Input

2 1 0


Output

FIRST
1 0 1 1


Input

2 2 4
0 1 2 1
0 1 2 1
1 2 1 0
1 1 1 2


Output

SECOND

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
void Get(int &T) {
  char C;
  bool F = 0;
  for (; C = getchar(), C < '0' || C > '9';)
    if (C == '-') F = 1;
  for (T = C - '0'; C = getchar(), C >= '0' && C <= '9'; T = T * 10 + C - '0')
    ;
  F && (T = -T);
}
set<pair<int, pair<int, int> > > S;
map<int, int> Sum;
int N, M, K;
void Add(int i, int l, int r) {
  typeof(S.begin()) k = S.insert(make_pair(i, make_pair(l, r))).first;
  for (;;) {
    typeof(k) p = k;
    p--;
    if (p->first == i && p->second.second >= l) {
      if (l > p->second.first) l = p->second.first;
      if (r < p->second.second) r = p->second.second;
      S.erase(p);
      S.erase(k);
      k = S.insert(make_pair(i, make_pair(l, r))).first;
    } else
      break;
  }
  for (;;) {
    typeof(k) p = k;
    p++;
    if (p->first == i && p->second.first <= r) {
      if (r < p->second.second) r = p->second.second;
      S.erase(p);
      S.erase(k);
      k = S.insert(make_pair(i, make_pair(l, r))).first;
    } else
      break;
  }
}
int SG;
void Init() {
  Get(N);
  Get(M);
  Get(K);
  S.insert(make_pair(0xc0c0c0c0, make_pair(0, 0)));
  S.insert(make_pair(0x3f3f3f3f, make_pair(0, 0)));
  for (int i = 1, X1, Y1, X2, Y2; i <= K; i++) {
    Get(X1);
    Get(Y1);
    Get(X2);
    Get(Y2);
    if (X1 > X2) std::swap(X1, X2);
    if (Y1 > Y2) std::swap(Y1, Y2);
    if (X1 == X2) Add(X1, Y1, Y2);
    if (Y1 == Y2) Add(-Y1, X1, X2);
  }
  int Last = 0;
  for (typeof(S.begin()) k = S.begin(); k != S.end(); k++) {
    if (k->first >= -M && k->first <= N) {
      if (k->first != Last) {
        if (k->first > 0)
          Sum[k->first] = M;
        else
          Sum[k->first] = N;
      }
      SG ^= Sum[k->first];
      Sum[k->first] -= k->second.second - k->second.first;
      SG ^= Sum[k->first];
    }
    Last = k->first;
  }
  if ((N - 1) & 1) SG ^= M;
  if ((M - 1) & 1) SG ^= N;
}
void Find(int X, int Dlt) {
  int R = 0;
  typeof(S.begin()) k =
      S.lower_bound(make_pair(X, make_pair(0xc0c0c0c0, 0xc0c0c0c0)));
  for (;; k++) {
    if (Dlt <= k->second.first - R || k->first != X) {
      R += Dlt;
      break;
    } else {
      Dlt -= k->second.first - R;
      R = k->second.second;
    }
  }
  puts("FIRST");
  if (X > 0)
    printf("%d %d %d %d\n", X, 0, X, R);
  else
    printf("%d %d %d %d\n", 0, -X, R, -X);
  exit(0);
}
void Work() {
  if (SG == 0) return;
  if ((SG ^ M) < M) {
    int Dlt = M - (SG ^ M);
    for (int i = 1; i < N; i++) {
      if (Sum.count(i) == 0) {
        Find(i, Dlt);
      }
    }
  }
  if ((SG ^ N) < N) {
    int Dlt = N - (SG ^ N);
    for (int i = 1; i < M; i++)
      if (Sum.count(-i) == 0) {
        Find(-i, Dlt);
      }
  }
  for (typeof(Sum.begin()) k = Sum.begin(); k != Sum.end(); k++) {
    if ((SG ^ (k->second)) < (k->second)) {
      int Dlt = (k->second) - (SG ^ (k->second));
      Find(k->first, Dlt);
    }
  }
}
void Output() { puts("SECOND"); }
int main() {
  Init();
  Work();
  Output();
  return 0;
}