Untitled
Never
import java.util.Scanner; public class Main { public static int findRotationLevel(String str1, String str2) { for (int i = 1; i <= str1.length(); i++) { if (str2.contains(str1.substring(i) + str1.substring(0, i))) { return i; } } return -1; } public static void main(String[] args) { Scanner sc = new Scanner(System.in); String[] str = sc.nextLine().split(" "); int rotationLevel = findRotationLevel(str[0], str[1]); System.out.println(rotationLevel); } }
Raw Text
-
ghjnhnmj ghbn bhgfbv gb
38 min ago
-
Untitled
55 min ago
-
c..h...i.l...d...p...r...o...n
1 hour ago
-
t33nleaks
1 hour ago
-
Untitled
1 hour ago
-
cp
1 hour ago
-
🍑🍑🍑 NEW CP UPDATE MAY 2024 VIDEOS WORKING ALL FREE FOLDER 🍑🍑🍑
1 hour ago
-
Untitled
1 hour ago
-
Adult Telegram Channels
3 hours ago
-
The Success Vitamin - Your Sales Trainer in India
3 hours ago