we define str s n string str consist string s concatenate n timesFor example str abc 3 abcabcabcWe define string s1 obtain string s2 remove character s2 s1For example s1 abc obtain s2 abdbec base definition remove bolde underlined charactersYou give string s1 s2 integer n1 n2 you string str1 s1 n1 str2 s2 n2Return maximum integer m str str2 m obtain str1 Example 1input s1 acb n1 4 s2 ab n2 2Output 2example 2input s1 acb n1 1 s2 acb n2 1output 1 Constraints1 s1length s2length 100s1 s2 consist lowercase english letters1 n1 n2 106