SRM 597 Div2 500
程序员文章站
2024-01-13 15:57:04
...
Little Elephant from the Zoo of Lviv likes strings. You are given a string A and a string B of the same length. In one turn Little Elephant can choose any character of A and move it to the beginning of the string (i.e., before the first ch
Little Elephant from the Zoo of Lviv likes strings.
You are given a string A and a string B of the same length. In one turn Little Elephant can choose any character of A and move it to the beginning of the string (i.e., before the first character of A). Return the minimal number of turns needed to transform A into B. If it's impossible, return -1 instead.
上一篇: PHP施用DES进行加密和解密
下一篇: sql多条件排序语句