#include <bits/stdc++.h>
using namespace std;
char chess[10][10];
char r[2][10] = {"BWBWBWBW", "WBWBWBWB"};
int main() {
  int i, j;
  bool flag = true;
  for (i = 0; i < 8; i++) {
    scanf("%s", chess[i]);
    if (strcmp(chess[i], r[0]) != 0 && strcmp(chess[i], r[1]) != 0)
      flag = false;
  }
  printf("%s\n", flag ? "YES" : "NO");
  return 0;
}
