If any two strings are not rotations of each other , we can 't make them same.
if ( index == len ( arr [ i ] ) ) : NEW_LINE INDENT return - 1 NEW_LINE DEDENT curr_count += index NEW_LINE ans = min ( curr_count , ans ) NEW_LINE return ans NEW_LINE