#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  int n = 8;
  while (n--) {
    cin >> s;
    for (int i = 1; i < s.size(); ++i) {
      if (s[i - 1] == s[i]) {
        cout << "NO";
        return 0;
      }
    }
  }
  cout << "YES";
  return 0;
}
