My problem is to find the repeating sequence of characters in the given array. simply, to identify the pattern in which the characters are appearing.
Put all your character in an array e.x. a[]
i=0; j=0; for( 0 < i < count ) { if (a[i] == a[i+j+1]) {++i;} else {++j;i=0;} }
Then the ratio of (i/j) = repeat count in your array. You must pay attention to limits of i and j, but it is the simple solution.
i
j