# s1→s2 每次只能移动一个字母到最后,求移动的最少次数 if __name__ == "__main__":     s1=str(input('1'))     s2=str(input('2'))     if len(s1)!=len(s2):         print(-1)     elif sorted(s1)!=sorted(s2):         print(-1)     else:         i=0         flag=False         for j in range(len(s2)):              if flag==True:                 print(len(s1)-j+1)                 break                 while True:                 if i==len(s1):                     flag=True                     break                 if s1[i]==s2[j]:                     i+=1                     break                   else:                     i+=1