[C] memset / memset.c / memset in c
2022. 7. 25. 17:37ㆍ🧑🏻💻/C & C++
void *memset(void *b, int c, size_t len)
{
unsigned char *temp_b;
temp_b = (unsigned char *)b;
while (len--)
*temp_b++ = (unsigned char)c;
return (b);
}
'🧑🏻💻 > C & C++' 카테고리의 다른 글
[C] strjoin / strjoin.c / strjoin in c (0) | 2022.09.14 |
---|---|
[C] substr / substr.c / substr in c (0) | 2022.09.14 |
[C] memmove / memmove.c / memmove in c (0) | 2022.07.25 |
[C] memcpy / memcpy.c / memcpy in c (0) | 2022.07.25 |
[C] memcmp / memcmp.c / memcmp in c (0) | 2022.07.25 |