1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
iogann1982 [59]
3 years ago
13

Assume you are using the text's array-based queue and have just instantiated a queue of capacity 10. You enqueue 5 elements and

then deque elements. Which indices of the internal array elements hold the remaining elements? a) 0 to 2 b) 7 to 9 c) 2 to 4 d) 1 to 3
Computers and Technology
1 answer:
Anika [276]3 years ago
7 0

Full question:

Assume you are using the text's array-based queue and have just instantiated a queue of capacity 10. You enqueue 5 elements and then deque 2 elements. Which indices of the internal array elements hold the remaining elements? a) 0 to 2 b) 7 to 9 c) 2 to 4 d) 1 to 3

Answer and Explanation:

If you instantiate a capacity of 10 for the queue, you have the queue a capacity of not more than 10 values.

To enqueue means to add an element to the array(if it's not full, n<10)

To dequeue means to delete an element from the array or queue(if n! =0)

From the question, for example:

We create a queue of capacity 10:

Queue q(10);

We add elements/enqueue 5 elements to the queue :

q.queueEnqueue(10);

q.queueEnqueue(5);

q.queueEnqueue(8);

q.queueEnqueue(9);

q.queueEnqueue(2);

If we print this out:

q. queueDisplay()

We would get:

10, 5, 8, 9, 2

We remove elements/dequeue 2 elements from the queue :

q. queuedequeue();

q. queuedequeue();

We print it out:

q. queueDisplay()

8 ,9, 2

We observe that deletion/dequeue starts from the front/first index.

We are left with indices 2, 3, 4 or 2 to 4

Note: the above methods/ functions and objects used are merely for example purposes. The queue uses a floating front design approach.

You might be interested in
Whenever I go onto Google Chrome, the words are in Spanish! How can I make the words be back in English again? Please let me kno
ivann1987 [24]

Answer:

Go to google setting look up english on setting bar and it should have the option to change or add languages make sure you press save when choosing english

Explanation:

5 0
3 years ago
A call center is a _______.<br><br> JIT<br><br> CMA<br><br> CIC<br><br> SFA
sp2606 [1]

Answer: CIC

Explanation:

A call center is a customer interaction center (CIC) and it is the interface between call center agent with the customers directly. CIC are connected by the external telephone system and it uses as call center.

And the caller are basically identify by the telephone number and customer information are display in the CIC.

CIC are the modular structure for communication which include various components of CIC and framework.

4 0
4 years ago
"an excel spreadsheet is an example of a(n ________ database."
Sonja [21]
Sometimes it is hard for some people to say thank you and to rate 5 star when correct so i will you deserve it thanks for adding a correct answer! have a great day!! 
8 0
3 years ago
Write a program that asks the user for the name of a text file. The program should display the first 10 lines of the file on the
tangare [24]

Answer:

Written in Python

filenm = input("File name: ")

myfile = open(filenm+".txt")

for i in range(10):

     line = myfile.readline()

     print(line)

print("End of file")

Explanation:

This line prompts user for file name

filenm = input("File name: ")

This line creates an instance of the file

myfile = open(filenm+".txt")

This line iterates through the 10 lines

for i in range(10):

This line reads the line

     line = myfile.readline()

This line prints each line

     print(line)

This line prints a message indicating that all possible lines have been printed

print("End of file")

5 0
3 years ago
Sql injections is an attack in which __ code is inserted into strings that are later passed to an instance of sql server.
jek_recluse [69]

Answer:

malicious code

Please Mark Brainliest If This Helped!

7 0
2 years ago
Other questions:
  • In 2-5 paragraphs, describe the points that Kendra needs to consider when choosing a telecommunications technology to meet her n
    6·1 answer
  • The technical relationship between inputs and outputs, which is needed to understand the difference between the short run and th
    5·1 answer
  • Write a statement containing a logical expression that assigns true to the
    13·1 answer
  • What are the opportunities, and challenges, forged by digital transformation?
    13·1 answer
  • [c++] Write a recursive function takes a word string as input argument and reverse the word. Print out the results of recursive
    14·1 answer
  • Remember to check the on your vehicle first to see if a repair is covered by the manufacturer.
    15·1 answer
  • 3.4 lesson practice quiz edhesive
    11·1 answer
  • Why is page formatting important??​
    10·2 answers
  • Order the steps to add a recommended chart in excel.
    5·2 answers
  • Which describes a set amount of pay received by a worker over the course of a year?
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!