#include <bits/stdc++.h>
using namespace std;
void fast_input();
int main() {
  fast_input();
  char colors[4][4];
  for (int i = 0; i < 4; i++) {
    for (int j = 0; j < 4; j++) {
      cin >> colors[i][j];
    }
  }
  bool check = false;
  for (int i = 0; i < 4; i++) {
    for (int j = 0; j < 4; j++) {
      if (i + 1 < 4 && j + 1 < 4) {
        if (colors[i][j] == colors[i][j + 1] ||
            colors[i + 1][j] == colors[i + 1][j + 1]) {
          if (colors[i][j] == colors[i + 1][j] ||
              colors[i][j + 1] == colors[i + 1][j + 1]) {
            check = true;
            break;
          }
        }
      }
    }
    if (check) break;
  }
  if (check)
    cout << "YES\n";
  else
    cout << "NO\n";
  return 0;
}
void fast_input() {
  cin.tie(0);
  cin.sync_with_stdio(0);
}
