Home > dev > api > name > gb.count 
 en fr de es it nl pl pt pt_BR mk sq ca hu tr ar fa id vi ko ja ru zh zh_TW eo
Previous  Next  Edit  Rename  Undo  Search  Administration  
Documentation  
Warning! This page is not translated.  See english version 
GB.Count
long GB.Count ( void *array )

Returns the number of elements in an array.

The parameter is a direct pointer to the data. It is not the same parameter syntax than GB.NewArray, GB.FreeArray and GB.Add.

Example

/* Creates and delete an array of integers with n slots and gets its number of elements */

int *array;
long count;

GB.NewArray((void *)&array, sizeof(*array), n);
count = GB.Count(array);

See also

api/cat/marray