Stacks in C++ (this stack is using linked structure)
View Paper
ESSAY DETAILS
Words: 1642
Pages: 6
(approximately 235 words/page)
Pages: 6
(approximately 235 words/page)
Essay Database > Science & Technology > Computers and Cybernetics
/********************************************************************
* file: stack.cpp *
* desc: C++ assignment *
* Author: Syed R Fayyaz *
* Date: 03-30-2004 *
* *
* Comment: To introduce with the concept of PUSH, pop and display *
*with stacks. Stack is implemented using linked structure*
*which is little difficult from array ADT's but good for *
*polishing programming skills. *
********************************************************************/
//preprocessor Directives
#include<iostream.h>
#include<conio.h>
#include<iomanip.h>
// global declarations
//STRUCTURE DEFINITION
/* This ADT "stack_node" includes 2 parts one is data
showed first 75 words of 1642 total
Sign up for EssayTask and enjoy a huge collection of student essays, term papers and research papers. Improve your grade with our unique database!
showed first 75 words of 1642 total
showed last 75 words of 1642 total
break_info); //Displays window status and username cout << "n| Main Menu |" ; //Telling user what he can do cout << "nnntWELCOME " << "nntOption [1] will bring you on this page!" << "nntOption [2] will push a value to stack!" << "nntOption [3] will pop a value from stack!" << "nntOption [4] will display the contents!" << "nntOption [5] is Exit from the program!"; //Formatting line information for bottom menu line_break_info+=14; return; }
break_info); //Displays window status and username cout << "n| Main Menu |" ; //Telling user what he can do cout << "nnntWELCOME " << "nntOption [1] will bring you on this page!" << "nntOption [2] will push a value to stack!" << "nntOption [3] will pop a value from stack!" << "nntOption [4] will display the contents!" << "nntOption [5] is Exit from the program!"; //Formatting line information for bottom menu line_break_info+=14; return; }