Problem:
Score : 1000 points

Problem Statement

There are N integers written on a blackboard. The i-th integer is A_i, and the greatest common divisor of these integers is 1.

Takahashi and Aoki will play a game using these integers. In this game, starting from Takahashi the two player alternately perform the following operation:

Select one integer on the blackboard that is not less than 2, and subtract 1 from the integer.

Then, divide all the integers on the black board by g, where g is the greatest common divisor of the integers written on the blackboard.

The player who is left with only 1s on the blackboard and thus cannot perform the operation, loses the game.
Assuming that both players play optimally, determine the winner of the game.

Constraints

1 ≦ N ≦ 10^5

1 ≦ A_i ≦ 10^9

The greatest common divisor of the integers from A_1 through A_N is 1.

Input

The input is given from Standard Input in the following format:

N
A_1 A_2 … A_N

Output

If Takahashi will win, print First. If Aoki will win, print Second.

Sample Input 1

3
3 6 7

Sample Output 1

First

Takahashi, the first player, can win as follows:

Takahashi subtracts 1 from 7. Then, the integers become: (1,2,2).

Aoki subtracts 1 from 2. Then, the integers become: (1,1,2).

Takahashi subtracts 1 from 2. Then, the integers become: (1,1,1).

Sample Input 2

4
1 2 4 8

Sample Output 2

First

Sample Input 3

5
7 8 8 8 8

Sample Output 3

Second

Solution in C++14 (GCC 5.4.1) (judge verdict: Accepted)

#pragma warning(disable:4996)

#include <stdio.h>
#include <iostream>
#include <iomanip>
#include <vector>
#include <algorithm>
#include <string.h>
#include <stdlib.h>
#include <assert.h>
#include <cmath>
#include <map>
#include <set>
#include <queue>
#include <complex>
#include <iterator>
#include <random>
#include <time.h>
#include <tuple>
#include <functional>
#include <list>
#include <limits.h>
#define mp make_pair
#define ni(x) scanf("%d", &(x))
#define nii(x,y) scanf("%d%d",&(x),&(y))
#define mul(x,y) ((ll)(x)*(y)%mod)
#define mtp make_tuple
#define F(i,n) for(int i = 0; i < (n); i++)
#define FF(i,n) for(int i = 1; i <= (n); i++)
#define FE(i,n) for(int i = 0; i <= (n); i++)

using namespace std;
typedef pair<int, int> pii;
typedef long long ll;
const int mod = 1000000007;
const int inf = 2012345678;
const ll infl = 9012345678901234567;
const double pi = 3.1415926535897932384626433832795;
//----------------------------------------------------------------------------//

const int N = 100000;
int a[N];
int gcd(int a, int b) {
	if (!b)return a;
	else return gcd(b, a%b);
}

bool solve(vector<int>& a) {
	int n = a.size();
	bool eq = false;
	ll sum = 0;
	F(i, n) {
		if (a[i] == 1)eq = true;
		sum += a[i];
	}
	if (eq) {
		if (sum % 2 == n % 2) {
			return false;
		}
		else {
			return true;
		}
	}
	int cnt = 0;
	F(i, n) {
		if (a[i] % 2 == 0) cnt++;
	}
	if (cnt & 1) {
		return true;
	}
	if (cnt != n - 1) {
		return false;
	}
	F(i, n)if (a[i] & 1)a[i]--;
	int gg = a[0];
	F(i, n) {
		gg = gcd(gg, a[i]);
	}
	F(i, n)a[i] /= gg;

	return !solve(a);
}

int main() {
#ifndef __GNUG__
	freopen("input.txt", "r", stdin);
	//freopen("output.txt", "w", stdout);
#endif
	vector<int> V;
	int n; ni(n);
	F(i, n) {
		int x; ni(x);
		V.push_back(x);
	}
	if (solve(V))puts("First");
	else puts("Second");

	return 0;
}