public static void Main()
int[] arrA = new int[7]{1,2,3,5,6,7,8};
int[] arrB = new int[7] {5,6,7,8,1,2,3};
ArrayChecks arrayCheck = new ArrayChecks();
bool result = arrayCheck.IsRoated(arrA, arrB);
Console.WriteLine("Result Status: " + result);
public bool IsRoated(int[] arrA, int[] arrB)
for(int i = 0;i < arrA.Length && entryPostion == -1; i++)
for(int x = 0;x < arrB.Length; x++){
if(arrA[i] == arrB[x] && entryPostion == -1){
int arrbCount = entryPostion;
for(int i = 0; i < arrA.Length;i++)
if(arrbCount > (arrA.Length - 1))
if(arraCount > (arrA.Length - 1))
int currA = arrA[arraCount];
int currB = arrB[arrbCount];
nextA = arrA[arraCount + 1];
} catch ( IndexOutOfRangeException){
nextB = arrB[arrbCount + 1];
} catch ( IndexOutOfRangeException){