Inheritance and polymorphism, C/C++ Programming

The zipped folder int_collection.zip (downloaded from Blackboard) contains an abstract class AbstractIntCollection and two interfaces: IntList and IntStack. The abstract class contains support for the development of array based data structures. The two interfaces de ne the functionality of an integer list and an integer stack. Your task is to implement the two interfaces by inheriting from the abstract class, that is, create two classes with the following signatures:

public class ArrayIntList extends AbstractIntCollection implements IntList

public class ArrayIntStack extends AbstractIntCollection implements IntStack

Also write a test program CollectionMain, showing the functionality of the classes. Note: Your classes are supposed to use the abstract class and the interfaces exactly as they are given. You are not allowed to change ANYTHING in those classes (except from the package declaration).

Posted Date: 3/14/2013 5:52:26 AM | Location : United States







Related Discussions:- Inheritance and polymorphism, Assignment Help, Ask Question on Inheritance and polymorphism, Get Answer, Expert's Help, Inheritance and polymorphism Discussions

Write discussion on Inheritance and polymorphism
Your posts are moderated
Related Questions
Various ways of initializing the Arrays. - The for loop initializes 10 elements with the value of their index.      void main()     {                 const in

What does throw; (with no exception object after the throw keyword) mean? Where would I employ it? A: You should see code that looks something like this: class MyException

Define Pure Virtual Function? Why & when it is used?

C Program for FUNCTION OF COUNT THE CHARACTERS IN EACH WORD void count(char c[]); void main() {           char a[50];           int i=0;           clrscr();

Integer literal Integer is numbers without fractional parts. e.g. 20       // Decimal 024      // Octal     0x14     // Hexadecimal To indicate long, unsigned,

Damjibhai and Shamjibhai are two jeweler friends. They decide to play a simple game. The game comprises of removing the jewels for polishing, turn by turn. Once a jewel is removed

Want an EA project for Jack Bsher Project Description: New EA game Skills required   Android, C++ Programming, PHP, Metatrader, SQL

The goto statement This statement can be used to branch to another statement of the program. This is rarely used as it violates the principle of structured programming. Though

Question: (a) Write short notes on arrays. Extend your answer by putting emphasis on memory allocation. (b) Write a C++ program to input an integer n followed by n real-

Conversion from Basic to User-Defined variable Consider the following example. class Distance                  {                   public  :