ArrayList/ArrayList.c
ArrayList* createArrayList(size_t capacity) {
    ArrayList* list = malloc(sizeof(ArrayList));
    if (list == NULL)
        return NULL;
    list->size = 0;
    list->capacity = capacity;
    list->elements = malloc(sizeof(void*) * capacity);
    
    return list;
}
/**
* A function that creates and returns a pointer to an ArrayList for usage, returns NULL on error
*/
A function that creates and returns a pointer to an ArrayList for usage, returns NULL on error
A function that creates and returns a pointer to an ArrayList for usage returns NULL on error
ArrayList* createArrayList(size_t capacity) {
    ArrayList* list = malloc(sizeof(ArrayList));
    if (list == NULL)
        return NULL;
    list->size = 0;
    list->capacity = capacity;
    list->elements = malloc(sizeof(void*) * capacity);
    return list;
}
ArrayList * createArrayList ( size_t capacity ) { ArrayList * list = malloc ( sizeof ( ArrayList ) ) ; if ( list == NULL ) return NULL ; list -> size = 0 ; list -> capacity = capacity ; list -> elements = malloc ( sizeof ( void * ) * capacity ) ; return list ; }
A function that creates and returns a pointer to an ArrayList for usage, returns NULL on error
A function that creates and returns a pointer to an ArrayList for usage returns NULL on error