⌨️
[AtCoder]ABC-103|B - String Rotation
設問ページ
提出結果
def getString():
return input()
def main():
s = getString()
t = getString()
r = 'No'
for i in range(len(s)):
if t == (s[i:] + s[:i]):
r = 'Yes'
break
print(r)
if __name__ == "__main__":
main()
Discussion