 Hello friends, I am Sanjay Gupta. In this video, I am going to demonstrate you how you can copy reverse of an array into another array. Before starting, you can note my information, you can follow or subscribe my YouTube channel through this URL that is youtube.com slash sanjaygupta underscore tax school. You can download my programming app, Techimus, which is available on Google Play. Now coming onto the topic, here in this program, I am first receiving an array from user, then I will be copying its reverse into another array with the help of C program. So you can see I have implemented small segment of code in front of you. Here two arrays A and B are declared, then IJ two variables are declared. Using printf enter elements, masses will be displayed on console and with the help of this for loop 10 elements will be received inside a array. Now after receiving all 10 elements, I am going to implement another loop starting from I equals to zero and J equals to nine. So I am initializing two variables here I zero and J nine condition is I less than 10. So array is containing 10 elements. That's why I have to repeat this loop 10 times and then I plus plus and J minus minus. Now inside this loop I have to implement the code so that I can copy value of A into B in reverse order. So here I am writing B of J equals to A of I. So now see this statement. I is pointing to zero index. So A zero will be stored in BJ. J is pointing to nine. So ninth index of B array will be receiving the value which is stored at A zero index. So simply we can say first element of A array is stored at last location of B array. Then I plus plus this will make I one and J minus minus so J will become eight. So second time first index or you can say value which is available at first index of A array will be stored at eighth index of B array. So this way A array will be stored in reverse order inside B array. Now after completion of this loop I have to print B array. So I can show this message reverse of array then for I equals to zero I less than 10 I plus plus and with this follow I am going to print values of B array. Now you can see I have implemented the complete code. It is divided into three segments. First segment is reading 10 elements in A array. Then second segment is copying values of A array into B in reverse order. And third segment is printing reverse of A with the help of B because B is containing values of A in reverse order. So this way I have implemented this code in C programming. Now I am executing this code. You can see it is asking for 10 numbers. So I have entered 10 numbers and you can see the output reverse of array. The entered values are printing in reverse order. So this way I have copied all the elements of A array into B array in reverse order. Now I am going to remove this J variable from this loop and here in place of J I am writing nine minus I. So now check this logic. I is zero. So A will be assigning zero index value into B nine minus I. So I is zero. So it will become nine. So B array ninth index will be receiving that value. Then I plus plus I will become one. So A one will be assigned into A nine minus one. So it will become eight. So B arrays eight index will be receiving the value which is available at A one. So this way all the elements of A array will be stored inside B array in reverse order. So with help of this I variable only we can manage indexes of two different very two different arrays. Now I am executing this code. You can see it is again asking for 10 numbers. I am entering 10 values and you can see the output. The reverse of array is printing properly. So friends this way I have demonstrated you how you can copy reverse of an array into another array. So this way the complete code is explained and it is available in front of you. I hope you have understood all the logics which I have demonstrated you. If you want to watch more programming related videos you can follow or subscribe my YouTube channel through the URL youtube.com slash sanjaygupta underscore tax pool. You can also download my programming at TechMS which is available on Google Play. So if you want to learn programming or you want to watch more programming related videos you can keep connected with me. Thank you for watching this video.