#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const int MOD = 100000007;
const int maxn = 55555;
int main() {
  char ss[5000];
  cin.getline(ss, 5000);
  string str = ss;
  char ch;
  for (int i = 0; i < (str.size()); i++) {
    if (isalpha(str[i])) ch = tolower(str[i]);
  }
  char ssss[7] = "aiouye";
  for (int i = 0; i < (6); i++) {
    if (ch == ssss[i]) {
      cout << "YES";
      return 0;
    }
  }
  cout << "NO";
  return 0;
}
