Google Answers Logo
View Question
 
Q: C++ Programming Help Needed ( No Answer,   2 Comments )
Question  
Subject: C++ Programming Help Needed
Category: Computers > Programming
Asked by: cbakhru-ga
List Price: $50.00
Posted: 04 May 2006 23:42 PDT
Expires: 03 Jun 2006 23:42 PDT
Question ID: 725640
1.) Beginning with something like the following: 

     template class ArrayObject
     {
          protected: 
               T Ary[MaxSize]; 
               int Current; 
               int Full; 
               int Empty; 
          public: 
               ArrayObject();
               int IsFull();
               int IsEmpty();
               void Show();
               void Increment();
               void Decrement();
     } 

     Construct a STACK CLASS TEMPLATE and a QUEUE CLASS 
     TEMPLATE as using the above CLASS TEMPLATE as a BASE CLASS. 

2.) Write all the MEMBER FUNCTIONS called for using OVERLOADING to
implement the following operations:
     PUSH - StackVar += Element
     POP - Element = StackVar--
     TOP - Element = --StackVar
     ENQUEUE - QueueVar += Element
     DEQUEUE - Element = QueueVar--
     FRONT - Element= --QueueVar 

3.) Separately compile the CLASS TEMPLATES. 

4.) Write a separate program which uses INSTANCES of your CLASS
TEMPLATES to perform the following:

     - Evaluate 10 POSTFIX integer expressions using a INTEGER STACK. 

     - Enqueue each result using a INTEGER QUEUE. 

     - Dequeue and print all 10 results from the INTEGER QUEUE when
you are finished.
Answer  
There is no answer at this time.

Comments  
Subject: Re: C++ Programming Help Needed
From: jiangsheng-ga on 05 May 2006 13:28 PDT
 
Most of us have done them ourselves. Those questions are for you to
work out, so that you will learn from the experience. It is OK to ask
for hints, but not for entire solutions.
--Eric S. Raymond
Subject: Re: C++ Programming Help Needed
From: srirangan-ga on 14 May 2006 08:57 PDT
 
Why should we do your homework?

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy