ca

来自「Algorithms for Image Processing and Comp」· 代码 · 共 30 行

TXT
30
字号
@c ----------------------------------------------------------------------
@node calloc, memory
@heading @code{calloc}
@subheading Syntax

@example
#include <malloc.h>

void *calloc(size_t num_elements, size_t size);
@end example

@subheading Description

This function allocates enough memory for @var{num_elements} objects of
size @var{size}.  The memory returned is initialized to all zeros.  The
pointer returned should later be passed to cfree (@pxref{cfree}) so that
the memory can be returned to the heap. 

@subheading Return Value

A pointer to the memory, or @code{NULL} if no more memory is available.

@subheading Example

@example
Complex *x = calloc(12, sizeof(Complex));
cfree(x);
@end example

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?