Skip to content
Snippets Groups Projects
Commit cf9ddf4c authored by orestis.malaspin's avatar orestis.malaspin
Browse files

Merge branch '8-add-get-length-function' into 'main'

"Add get length function"

Closes #8

See merge request !15
parents 1dec4649 9d7603c5
Branches
Tags
1 merge request!15"Add get length function"
# stack
......@@ -40,3 +40,8 @@ void stack_clone(stack s, stack *clone) {
}
}
int get_length(stack s)
{
return s->top + 1;
}
......@@ -11,6 +11,7 @@ void stack_init(stack *stack);
void stack_peek(stack s, int *value);
void stack_clone(stack s, stack *clone);
int get_length(stack s);
void stack_print(const stack s);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment