import java.util.*; public class Exercise81{ public static void main (String[] args){ Scanner sc = new Scanner(System.in); String weekOne = sc.next(); String weekTwo = sc.next(); String twoWeeks = weekOne + weekTwo; String[] weekArray = twoWeeks.split("x"); Arrays.sort(weekArray); System.out.println((weekArray.length == 0) ? 0 : weekArray[weekArray.length - 1].length()); } }