#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 5;
int c, n, h[N], wh[N];
bool check(int x) {
  int rem = c;
  int cur = wh[c];
  while (cur > x) {
    rem -= min(rem / cur, h[cur]) * cur;
    cur = min(wh[rem], wh[cur - 1]);
  }
  if (rem >= x) rem -= x;
  while (cur > 0) {
    rem -= min(rem / cur, h[cur]) * cur;
    cur = min(wh[rem], wh[cur - 1]);
  }
  return rem > 0;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  cin >> c >> n;
  for (int i = 1; i <= n; i++) {
    int x;
    cin >> x;
    h[x]++;
  }
  for (int i = 1; i <= c; i++) {
    if (h[i])
      wh[i] = i;
    else
      wh[i] = wh[i - 1];
  }
  for (int i = 0; i <= c; i++)
    if (check(i)) {
      cout << i << endl;
      return 0;
    }
  cout << "Greed is good" << endl;
}
