Hello Together,

I have an important question.

I have a task where I need your help.

this is the question.

```
Given! Be! Two! Equal! Long! Arrays:!
int[] a = {1,2,3,4};
int[] b = {10, 20, 30, 40};
Create a new array c that alternately contains all the values of a and b, that is, the value of the array.
then the first value of a, then the first value of b, then the second value of a, etc.
Your output in the example should look like this
[0]!1!
[1]!10!
[2]!2!
[3]!20!
[4]!3!
[5]!30!
[6]!4!
[7]!40!
Your function should work for any value (and any number of values) for any number of values for a and b.
as long as the length of both a and b is the same.
```

Now I have made two for loops.

This is my solution but its not correct:

```
int[] a = {1, 2, 3, 4};
int[] b = {10, 20, 30, 40};
int[]c = new int[a.length + b.length];
for(int i =0; i<a.length; i++)
{
c[i] = a[i];
}
for(int j=0; j <b.length; j++)
{
c[j + a.length] = b[j];
}
println(c);
```

How I can switch the array places where the c array starts at first with a[0] then with b[0] and so on?

Could someone give me a hint.

Then I will try it again.

Thank you.

Best wishes.

gurki