Add stack with dynamic array