View Single Post
Old 04-23-2019, 02:57 AM   #2
travelowebseo
Registered User
 
Join Date: Sep 2017
Posts: 224
Hi,
Check if the length of both Strings is same or not, If not then they are not rotation.
Check if both Strings are equal, if yes then strings2 is a rotation of strings1.
Take the first string's first character and find the index in the second string.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
travelowebseo is offline   Reply With Quote