Stack implementation using array in C