Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Data Structure and Methods:

  • Build an array structure to accomodate at least 10 elements. Provide routines for the following:
  • An initializer.
  • A routine to populate (add an element) to the first available slot,
  • A routine to delete (remove an element) from a chosen slot,
  • A routine to display the number of filled slots,
  • A routine to show the maximum number of slots,
  • A routine to query the contents of a slot,
  • A routine to update the information in a slot,
  • Test for full and empty conditions of the Array.

Testing:

Write (a) program(s) that tests each of the methods used to manipulate the data structure:

  • Construction.
  • Populate the available slots until the structure is full, then attempt to add one more.
  • Query the contents of a all slots.
  • Remove the contents of a given slot.
  • Update the contents of a slot.
  • Deplete the structure until all slots are empty, then attempt to delete another .

When displaying the full structure use a loop that shows 1 slot and its content, at a time.

Your program should employ a simple menu that repeatedly prompts the user to perform the functions.

Example: Enter an Request Type

1 To add elements in to the Array (until 1 or null)

2 To remove an element out of the Array

3 To display the contents of the entire Array

4 To query the count of occupied slots

5 - To query the maximum number of slots

6 To update an Array slot with a new information value

7 To find the location of a given value

8 Exit

Show all inputs, outputs, explanation of return codes, and informational messages.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M9529989

Have any Question?


Related Questions in Computer Engineering

Question suppose you have a class whose objects are very

Question : Suppose you have a class whose objects are very, very large. Briefly, describe the advantages and drawbacks of call-by-value and call-by-reference for large objects. Describe a parameter passing mechanism that ...

What is unified threat management utm and the services it

What is Unified Threat Management (UTM) and the services it combines into one device. Does UTM holds true to the principle of defense-in-depth

What are the tax reforms included in the train lawhow would

What are the tax reforms included in the TRAIN law? How would it impact the bottom 60% of the households and the top 40% of the households? Lastly, how does the being proposed transfer scheme works? Source: https://opini ...

If no payments are made a loan of amount 44000 would

If no payments are made, a loan of amount $44000 would increase to $49103.89 after 2 years of monthly compounding interest. If instead, payments of $718.87 are made at the end of each month, how many years would it be un ...

Writing a research paperprepare a research paper on

Writing a Research Paper Prepare a research paper on Antisocial Personality Disorder. In this project, you will modify a research paper. You will add and format text and format the document using themes and paragraph for ...

System analysis and design1 explain the difference between

System Analysis and Design 1) Explain the difference between too much feedback and too little feedback and provide a scenario for each one (two scenarios are needed - one for a lot of feedback and one for too much) and w ...

Question suppose a network with 109 hostnames not including

Question : Suppose a network with 10^9 hostnames (not including the names of the nameservers themselves) uses non-recursive DNS. Assume that there is a single root nameserver, multiple local nameservers, and M levels of ...

Question monicas reading comprehension score 22nbspmean

Question: Monica's reading comprehension score = 22  Mean fourth grade reading comprehension score = 19  Standard deviation of the fourth grade's reading comprehension = 1.8  Monica's z-score in math = 2.2  Mean fourth g ...

What are content management systems cms describe the

What are Content Management Systems (CMS). Describe the challenges in implementing and maintaining CMS. Can internet search engines be considered as Content Management Systems - explain your answer.

What is the broadcast domain and ports for hubs and

What is the Broadcast Domain and Ports for hubs and bridges?

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As