#include <bits/stdc++.h>
char chess[10];
int i, j;
int main() {
  bool f = true;
  for (i = 0; i < 8; ++i) {
    for (j = 0; j < 8; ++j) {
      scanf("%c", &chess[j]);
      if (j > 0 && chess[j] == chess[j - 1]) {
        f = false;
      }
    }
    getchar();
  }
  if (!f)
    printf("NO\n");
  else
    printf("YES\n");
}
