#include <bits/stdc++.h>
using namespace std;
int main() {
  string a, at, b, c;
  cin >> a >> at >> b >> c;
  if (b == "#" && c == ".") {
    cout << "No" << endl;
  } else {
    cout << "Yes" << endl;
  }
}
