using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace template { class Program { static void Main(string[] args) { string s = Console.ReadLine() + Console.ReadLine(); int ret = 0; for (int i = 0; i < s.Length; i++) { if (s[i] == 'o') { int j; for (j = 0; i + j < s.Length && s[i + j] == 'o'; j++) ; ret = Math.Max(ret, j); } } Console.WriteLine(ret); } } }