I need to copy from end to start an array of longs to an array of longs as is shown in the code bellow. Is there any function similar to memcpy for the required purpose ?
typedef long int myT;
const size_t n=5;
myT a[n];
myT b[n]={12,45,56,76,78};
int main(int argc, char **argv)
{
myT *p1=&a[0];
myT *p2=&b[n];
for(auto i=n;i-->0;)
*p1++=*--p2;
return 0;
}