#include <stdbool.h>

#ifndef _STACK_H_
#define _STACK_H_

typedef struct _stack {
    int *data;
    int capacity;
    int top;
} stack;
void stack_push(stack *s, int val);

void stack_init(stack *stack);

void stack_destroy(stack *s);

void stack_pop(stack *s, int *value);
void stack_peek(stack s, int *value);
void stack_clone(stack s, stack *clone);
int get_length(stack s);
bool stack_is_empty(stack s);
void stack_clear(stack *s) ;

void stack_print(const stack s);

#endif