I will give you basic idea of it, you have to code it yourself.
See, create an array with some elements(odd and even both)
Now in a for loop check every element like this a[i] % 2 == 0, cuz if that condition is true then it's even number else it's odd number.
Code it 🤓
One way, while checking even or odd, if it comes even assign that into other array, if it is odd assign it into another array. So you have separate arrays for even and odd
While printing print one odd, one even element using loops.. Be sure to stop printing, continue other if array sizes are not same.. You can get while coding... Hope this helps some...