c++ - Push String in Stack? -


i using c++ , want push strings in stack push int in stacks.

for example

3."stackoverflow" 2."is" 1."best" 0."site" 

at every index of stack want push string. how can this?

using stl, example:

#include <stack>  std::stack<std::string> s; s.push("a"); s.push("b"); s.push("c"); s.push("d"); 

check stl reference more information.


Comments

Popular posts from this blog

c++ - Compiling static TagLib 1.6.3 libraries for Windows -

PostgreSQL 9.x - pg_read_binary_file & inserting files into bytea -

asp.net - call stack missing info on mono with apache and mod_mono -