using System; using System.Collections.Generic; using System.Linq; class Program { public void Solve() { List week = new List(); week.AddRange(Console.ReadLine().ToArray()); week.AddRange(Console.ReadLine().ToArray()); int holidayCnt = 0; int longHoliday = 0; for (int i = 0; i < week.Count(); i++) { if (week[i] == 'o') { holidayCnt++; } else { if (longHoliday < holidayCnt) { longHoliday = holidayCnt; } holidayCnt = 0; } } if (longHoliday < holidayCnt) { longHoliday = holidayCnt; } Console.WriteLine(longHoliday); } static void Main() { var solver = new Program(); solver.Solve(); } }