Write a function clears a stack


Discussion:

Q: Write a function

template
void stackClear (stack& s);

that clears a stack s. Why is it critical that s be passed by reference?

 

Solution Preview :

Prepared by a verified Expert
C/C++ Programming: Write a function clears a stack
Reference No:- TGS01937564

Now Priced at $20 (50% Discount)

Recommended (92%)

Rated (4.4/5)