import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); String input = sc.next() + sc.next(); int count = 0, max = 0; for(int i=0;i<14;i++){ if(input.charAt(i) == 'o'){ count = 0; for(int j=i;j<14;j++){ if(input.charAt(j) != 'o')break; count++; } max = Math.max(max,count); } } System.out.println(max); } }