sem2hw2task2: Added one implementation of stack based on pointers