data type of malloc and calloc in c code example Example: how to use malloc in c ptr = (cast-type*) malloc(byte-size)