// #define _GLIBCXX_DEBUG #include using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); ++i) int main() { // Input int Y, M, D; cin >> Y >> M >> D; // Output int first = 19890108; int last = 20190430; int pos = Y * 10000 + M * 100 + D; cout << (first <= pos && pos <= last ? "Yes" : "No") << endl; }