Using good OOP, write a C++ program that will compare two arrays to test for the same elements and multiplicity.   To begin, populate the arrays with the input files, comFile1.txt and comFile2.txt.   The elements in the arrays do not need to be in the same order for them to be considered similar.  For example:comFile1.txt TO array 1:    121    144    19    161    19    144    19    11comFile2.txt TO array 2:    11    121    144    19    161    19    144    19 NOTE: Professor mentioned that the array Size should be 300 as eh will be testing the code with different files other than these two he has provided for examples.  would be considered to have the same elements because 19 appears 3 times in each array, 144 appears twice in each array, and all other elements appear once in each array.Use pointer notation instead of array notation whenever possible.Display whether or not the arrays have the same elements and multiplicity.Use private member functions and variables.Use public member functions for a constructor (where appropriate) and a driver method only.These specifications do not give a list of method names to be used.  It is assumed the program will use several methods doing one task each.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Using good OOP, write a C++ program that will compare two arrays to test for the same elements and multiplicity.   To begin, populate the arrays with the input files, comFile1.txt and comFile2.txt.   The elements in the arrays do not need to be in the same order for them to be considered similar.  For example:

comFile1.txt TO array 1:    121    144    19    161    19    144    19    11
comFile2.txt TO array 2:    11    121    144    19    161    19    144    19

NOTE: Professor mentioned that the array Size should be 300 as eh will be testing the code with different files other than these two he has provided for examples. 


would be considered to have the same elements because 19 appears 3 times in each array, 144 appears twice in each array, and all other elements appear once in each array.

Use pointer notation instead of array notation whenever possible.

Display whether or not the arrays have the same elements and multiplicity.

Use private member functions and variables.
Use public member functions for a constructor (where appropriate) and a driver method only.

These specifications do not give a list of method names to be used.  It is assumed the program will use several methods doing one task each.

AI-Generated Solution
AI-generated content may present inaccurate or offensive content that does not represent bartleby’s views.
steps

Unlock instant AI solutions

Tap the button
to generate a solution

Knowledge Booster
Functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education