Is there a way to :
memcpy(m, k, sizeof(m))
where m[6] and k is much larger but you want to copy just a subset?
ie
something like
memcpy(m, k[3], sizeof(m)) where it starts at element k[3]
Printable View
Is there a way to :
memcpy(m, k, sizeof(m))
where m[6] and k is much larger but you want to copy just a subset?
ie
something like
memcpy(m, k[3], sizeof(m)) where it starts at element k[3]
Well
memcpy(m, k, sizeof(m))
is
memcpy(m, &k[0], sizeof(m))
So
memcpy(m, &k[3], sizeof(m))
is entirely reasonable.
Thanks