Given two strings A and B, find the minimum number of times A has to be repeated such that B is a substring of it. If no such solution, return -1.
执行用时 :12 ms, 在所有 C++ 提交中击败了97.00%的用户 内存消耗 :9.1 MB, 在所有 C++ 提交中击败了82.83%的用户