2024 11 03 Result796. Rotate String
문제Given two strings s and goal, return true if and only if s can become goal after some number of shifts on s.A shift on s consists of moving the leftmost character of s to the rightmost position.For example, if s = "abcde", then it will be "bcdea" after one shift.요약첫글자를 마지막으로 돌리면서 goal과 같은게 나오는지 검사풀이처음에는 String.substring으로 풀긴했는데 효율이 너무 안좋게 나오길레그냥 s 문자 안바꾸고 idx로 검하였다.코드class Solution { public..