Skip to content
Snippets Groups Projects
Select Git revision
  • e1b3230afec60b33024cb6e6cc4cabf8b16a5089
  • main default protected
2 results

cmake.check_cache

Blame
  • vectors.h 746 B
    /*
        Autheur		: Abivarman KANDIAH
        Date		: 22/02/2022
        Fichier		: vectors.h
        Descritpion : Vectors functions header
    */
    
    #ifndef _VECTORS_H_
    #define _VECTORS_H_
    
    #define VECTOR_INIT_CAPACITY 4
    
    #include <stdio.h>
    #include <stdlib.h>
    #include <stdint.h>
    #include <stdbool.h>
    #include <assert.h>
    
    typedef int type;
    typedef struct vector_* vector;
    
    vector vector_create();
    int vector_length(vector vec);
    void vector_push(vector vec, type element);
    type vector_pop(vector vec);
    void vector_set(vector vec, int index, type element);
    type vector_get(vector vec, int index);
    type vector_remove(vector vec, int index);
    void vector_insert(vector vec, type element, int index);
    void vector_empty(vector vec);
    void vector_free(vector vec);
    
    #endif