Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- class Program
- {
- static void Main()
- {
- string s = Console.ReadLine();
- string[] t1 = s.Split('0');
- string[] t2 = s.Split('1');
- for (int i = 0; i < t1.Length; i++)
- {
- if (t1[i].Length >= 7)
- {
- Console.WriteLine("YES");
- return;
- }
- }
- for (int i = 0; i < t2.Length; i++)
- {
- if (t2[i].Length >= 7)
- {
- Console.WriteLine("YES");
- return;
- }
- }
- Console.WriteLine("NO");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement