malloc is undefined

The malloc function is used in the C programming language to dynamically allocate memory. It is part of the standard library and is declared in the stdlib.h header file. The malloc function takes a single argument, which is the number of bytes of memory to allocate. It returns a pointer to the allocated memory, or NULL if the allocation fails. The allocated memory can be accessed using the returned pointer.