Hockey Bob loves playing hockey. One day, as he was watching a hockey match, he was writing the players' current positions on a piece of paper. To simplify the situation he depicted it as a string consisting of zeros and ones. A zero corresponds to players of one team; a one corresponds to players of another team. If there are at least 7 players of some team standing one after another, then the situation is considered dangerous. For example, the situation 0100110111111101 is dangerous and 1110111011101 is not. You are given the current situation. Determine whether it is dangerous or not. INPUT One Line containing a non-empty string S consisting of characters "0" and "1" 7 a OUTPUT Print "YES" if the situation is dangerous. Otherwise, print "NO". CONSTRAINTS 1 Slength of string < 100 Sample Output
Answers
Answered by
0
Answer:
fIdrhozf-jxurykcurfugh thyhDC shahsjdj
Explanation:
hsjsjdbndmdndnhrudbri
Similar questions