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>
#pragma comment(linker, "/STACK:200000000")
using namespace std;
template <typename T>
inline T Abs(T x) {
  return (x >= 0) ? x : -x;
}
template <typename T>
inline T sqr(T x) {
  return x * x;
}
template <typename T>
string toStr(T x) {
  stringstream st;
  st << x;
  string s;
  st >> s;
  return s;
}
inline int nextInt() {
  int x;
  if (scanf("%d", &x) != 1) throw;
  return x;
}
inline long long nextInt64() {
  long long x;
  if (scanf("%I64d", &x) != 1) throw;
  return x;
}
inline double nextDouble() {
  double x;
  if (scanf("%lf", &x) != 1) throw;
  return x;
}
const int INF = (int)1E9;
const long long INF64 = (long long)1E18;
const long double EPS = 1E-9;
const long double PI = 3.1415926535897932384626433832795;
const int MAXN = 100100;
inline bool intersect(const pair<int, int> &a, const pair<int, int> &b) {
  return max(a.first, b.first) <= min(a.second, b.second);
}
int getFirst(const map<int, vector<pair<int, int> > > &m) {
  for (int i = 1; i < INF; i++)
    if (!m.count(i)) return i;
  return -1;
}
map<int, vector<pair<int, int> > > mx, my;
int n, m, k, F, S;
int gran(vector<pair<int, int> > &a, int n, int len = 0) {
  sort((a).begin(), (a).end());
  vector<pair<int, int> > t(1, a[0]);
  for (int i = 0; i < (int)(a.size()); i++)
    if (intersect(t.back(), a[i]))
      t.back().second = max(t.back().second, a[i].second);
    else
      t.push_back(a[i]);
  S = F = -1;
  int ans = t[0].first + (n - t.back().second);
  for (int i = 0; i < (int)(t.size() - 1); i++) {
    int cur = t[i + 1].first - t[i].second;
    ans += cur;
  }
  if (ans >= len) {
    F = 0;
    int tmp = min(len, t[0].first);
    if (tmp > 0) {
      len -= tmp;
      S = tmp;
    }
    for (int i = 0; i < (int)(t.size() - 1); i++) {
      int cur = t[i + 1].first - t[i].second, tmp = min(len, cur);
      if (tmp > 0) {
        len -= tmp;
        S = tmp + t[i].second;
      }
    }
    tmp = min(len, n - t.back().second);
    if (tmp > 0) {
      len -= tmp;
      S = tmp + t.back().second;
    }
  }
  return ans;
}
int main() {
  n = nextInt();
  m = nextInt();
  k = nextInt();
  for (int i = 0; i < (int)(k); i++) {
    int x1 = nextInt();
    int YYYYYYYYYYYY1 = nextInt();
    int x2 = nextInt();
    int y2 = nextInt();
    if (x1 > x2) swap(x1, x2);
    if (YYYYYYYYYYYY1 > y2) swap(YYYYYYYYYYYY1, y2);
    if (x1 == x2) my[x1].push_back(make_pair(YYYYYYYYYYYY1, y2));
    if (YYYYYYYYYYYY1 == y2) mx[YYYYYYYYYYYY1].push_back(make_pair(x1, x2));
  }
  int g = 0;
  g ^= n * ((m - (int)mx.size() - 1) % 2);
  for (map<int, vector<pair<int, int> > >::iterator i = mx.begin();
       i != mx.end(); i++)
    g ^= gran(i->second, n);
  g ^= m * ((n - (int)my.size() - 1) % 2);
  for (map<int, vector<pair<int, int> > >::iterator i = my.begin();
       i != my.end(); i++)
    g ^= gran(i->second, m);
  if (g > 0) {
    if ((int)mx.size() != m - 1) {
      int ng = g ^ n;
      if (n > ng) {
        int y = getFirst(mx);
        cout << "FIRST" << endl;
        cout << 0 << " " << y << " " << n - ng << " " << y << endl;
        return 0;
      }
    }
    if ((int)my.size() != n - 1) {
      int ng = g ^ m;
      if (m > ng) {
        int x = getFirst(my);
        cout << "FIRST" << endl;
        cout << x << " " << 0 << " " << x << " " << m - ng << endl;
        return 0;
      }
    }
    for (map<int, vector<pair<int, int> > >::iterator i = mx.begin();
         i != mx.end(); i++) {
      int t = gran(i->second, n, g);
      int ng = t ^ g;
      if (t < ng) continue;
      gran(i->second, n, t - ng);
      if (F != -1) {
        cout << "FIRST" << endl;
        cout << F << " " << i->first << " " << S << " " << i->first << endl;
        return 0;
      }
    }
    for (map<int, vector<pair<int, int> > >::iterator i = my.begin();
         i != my.end(); i++) {
      int t = gran(i->second, m, g);
      int ng = t ^ g;
      if (t < ng) continue;
      gran(i->second, m, t - ng);
      if (F != -1) {
        cout << "FIRST" << endl;
        cout << i->first << " " << F << " " << i->first << " " << S << endl;
        return 0;
      }
    }
  }
  cout << "SECOND" << endl;
  return 0;
}