InterSystems IRIS edition of the code golf is a type of recreational computer programming competition in which participants strive to achieve the shortest possible source code that solves a certain problem using the ObjectScript language.
String rotation is when you take a word and move some of its letters to the end of the word, so the first letter becomes the second letter, the second letter becomes the third, and so on. Last letter becomes first. Rotation can happen only in one direction →.
Your task is to write a method that will receive two strings. It then must return an integer value of how many times needed to rotate the strings to be equal.
As usual shortest solution wins.