#include <stdio.h>
void copyArr(int *src, int *dest);
void showArrElem(int *arr);

int main() {
    int source[] = {100, 200, 300, 400, 500};
    int result[5];
    copyArr(source, result);
    showArrElem(result);

    return 0;
}

void copyArr(int *src, int *dest){
    while(*src != '\0'){
        *dest = *src; //element, not adr
        dest++, src++;
    }
    *dest = '\0';
}

void showArrElem(int *arr){
    while(*arr != '\0'){
        printf("%d ", *arr);
        arr++;
    }
    printf("\n");

}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: