Home > Back-end >  2021-02-12: how to judge whether two strings are rotating string?
2021-02-12: how to judge whether two strings are rotating string?

Time:02-12

2021-02-12: how to judge whether two strings are rotating string? # # f greatly architects a daily topic

CodePudding user response:

 
If (a==null | | b==null | | a. ength ()!=b.l ength ()) {
return false;
}
String b2=b + b;
The return of b2. The contains (a);
  • Related