#include <bits/stdc++.h>
int main() {
  int number = 0;
  char words[120] = {};
  scanf("%[^\n]", words);
  getchar();
  int i = 0;
  int length = strlen(words);
  int consecutiveTeams = 1;
  char previousLetter = 'a';
  for (i = 1; i < length; i++) {
    previousLetter = words[i - 1];
    if (words[i] == previousLetter) {
      consecutiveTeams += 1;
    } else {
      consecutiveTeams = 1;
    }
    if (consecutiveTeams >= 7) {
      break;
    }
  }
  if (consecutiveTeams >= 7) {
    printf("YES\n");
  } else {
    printf("NO\n");
  }
  return 0;
}
