memset() function in C with Example
memset() function in C
Function memset() is a library function of "string.h" – it is used to fill a block of memory with given/particular value. It is used when you want to fill all or some of the blocks of the memory with a particular value.
Syntax of memset():
memset(void *str, char ch, size_t n);
It fills the n blocks of str with ch.