All Questions
7 questions
2
votes
1
answer
85
views
A (Sort of) Generic Stack Implementation in C using Macros
I spent some time implementing a generic stack in C using macros. Apart from general bugs and bad practices in my code, I was wondering about the viability of an implementation like this that uses ...
7
votes
1
answer
378
views
Pseudo-Generic Array Stack in C
I have implemented an array based pseudo-generic stack in C using macros. The code works fine for all data types. Is it a good idea to implement such a data structure using macros?
array_stack.h
...
3
votes
2
answers
105
views
A Stack Implementation In C
I've written a very simple linked list based stack implementation and was wondering if this is the standard way to do it in C.
...
9
votes
4
answers
4k
views
Checking for parentheses balance in C
A recent assignment asks me to create a program that checks for parentheses balance in a given string. As I can't find any duplicate questions that have code written in C, I decided to post another ...
10
votes
1
answer
2k
views
Dynamic stack C implementation
I'm a C beginner. I'm studying and implementing some data structures. I'd like to get feedback.
This is a stack implemented with an dynamic array.
In main there ...
8
votes
3
answers
32k
views
Stack implementation using an array
I am trying a stack implementation using an array. I want to know if this approach is OK or if there is a logical problem. This program is working fine.
...
0
votes
2
answers
2k
views
Review implementation of stack by using array in C [closed]
This question has become long after many updates. Click here to go down.
I have implemented stack using arrays in C. Please give me suggestions on how to improve it. The purpose of writing it is ...