Is it legal to zero the memory of an array of doubles (using memset(…, 0, …)) or struct containing doubles?
memset(…, 0, …)
The question implies two different things:
As Matteo Italia says, that’s legal according to the standard, but I wouldn’t use it. Something like
double *p = V, *last = V + N; // N is count while (p != last) *(p++) = 0;
is at least twice faster.