I need help with how to copy array a into first portion of array b. Assume double a[11], b[34].
This is what I have so far:
double i = 0;
a[11];
b[34 (sizeof (a) ) ];
do
{
b[ i ] = a[ i ]
itt;
}
while ( i < sizeof (a) );
![]()
This is a discussion on Help to copy Array a into first portion of array b within the C Programming forums, part of the General Programming Boards category; I need help with how to copy array a into first portion of array b. Assume double a[11], b[34]. This ...
I need help with how to copy array a into first portion of array b. Assume double a[11], b[34].
This is what I have so far:
double i = 0;
a[11];
b[34 (sizeof (a) ) ];
do
{
b[ i ] = a[ i ]
itt;
}
while ( i < sizeof (a) );
![]()
Anna
memcpy() is your friend (well, ok, so is google)
hello, internet!
Thanks for your response but I'm a baby in C Programming -- please explain your reponse in laymans terms.![]()
Anna
memcpy() is the function most appropriate for this situation
google is the search engine most appropriate for any situation
hello, internet!
Thank you Salem!
Anna