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
Diano4ka-milaya [45]
4 years ago
9

Given the following sequence of names added to an ADT sorted list:nameListPtr->insertSorted("Tammie");nameListPtr->insertS

orted("Brenda");nameListPtr->insertSorted("Sarah");nameListPtr->insertSorted("Tom");nameListPtr->insertSorted("Carlos");What would be returned by the call nameListPtr-> getPosition("Tammie")a. 1b. 3c. 4d. 5
Computers and Technology
1 answer:
lesya692 [45]4 years ago
4 0

Answer:              

c. 4

Explanation:  

This will work as following:

Lets say first Tammie is inserted by this statement insertSorted("Tammie")

Next insertSorted("Brenda") statement adds Brenda on top of Tammie so the sequence is now

  1. Brenda  
  2. Tammie

Next insertSorted("Sarah"); statement inserts Sarah below Brenda and above Tammie so the sequence becomes:

  1. Brenda
  2. Sarah
  3. Tammie

Next insertSorted("Tom"); statement inserts Tom below Tammie so the sequence becomes:

  1. Brenda
  2. Sarah
  3. Tammie
  4. Tom

Lastly insertSorted("Carlos"); statement inserts Carlos above sarah and below brenda so the sequence becomes:

  1. Brenda
  2. Carlos
  3. Sarah
  4. Tammie
  5. Tom

Now the statement getPosition("Tammie") is called which returns the position value of Tammie. So as you can see above its position is 4th so output is 4.

You might be interested in
Digital cameras are less susceptible to UV light.Select one of the options below as your answer:A. TrueB. False
horrorfan [7]
<span>Digital cameras are less susceptible to UV light. TRUE. In fact, there is an existing photography called Ultraviolet Photography. It is a process of photography that records images by using the light from the ultraviolet spectrum. There are two possible ways to use UV in taking photographs: via reflected UV and UV induced fluorescence.</span>
4 0
3 years ago
Read 2 more answers
Jason Chang is creating photos of his restaurant for a new website. Some of the photos of the staff have red eye, others are bad
Nadusha1986 [10]

It is okay to modify photos digitally to improve their appearance as long as it doesn't show what they aren't producing.

<h3>What is Advertisement?</h3>

This is the act of persuading people to buy goods and services and is usually done with the aid of the media.

Pictures are usually taken which have to be in the best shape and quality in order to entice people to buy the goods thereby bringing about higher sales and profit for the company.

Read more about Advertisement here brainly.com/question/1020696

7 0
2 years ago
What is a neuromorphic chip?
Dominik [7]

Answer:

A neuromorphic computer is a machine comprising many simple processors / memory structures (e.g. neurons and synapses) communicating using simple messages (e.g. spikes). ... Neuromorphic computing systems excel at computing complex dynamics using a small set of computational primitives (neurons, synapses, spikes).

Explanation:

The structure of neuromorphic computers makes them much more efficient at training and running neural networks. They can run AI models at a faster speed than equivalent CPUs and GPUs while consuming less power. This is important since power consumption is already one of AI's essential challenges.

3 0
3 years ago
Based on the description below which website is more appropriate
I am Lyosha [343]

Answer:

D

Explanation:

8 0
3 years ago
Read 2 more answers
HELP FAST PLEASE
never [62]

Answer:

I am not sure can you explain a little more

7 0
2 years ago
Read 2 more answers
Other questions:
  • Dominick has been hired to design a network for Pirate Press. In a paragraph of no less than 125 words, discuss what he needs to
    12·2 answers
  • Which of the following is NOT an example of input?
    8·1 answer
  • Microsoft access does not create n:m relationships because microsoft access creates databases based on
    7·1 answer
  • The part of the computer that provides access to the internet is the?
    14·1 answer
  • Liquid-liquid extraction is best suited to separate a mixture of compounds when:
    9·1 answer
  • The function below takes two parameters: a string parameter: csv_string and an integer index. This string parameter will hold a
    5·1 answer
  • Quick!! Im taking a timed test so pls hurry!! Ill even mark as brainliets!!
    5·2 answers
  • What is the key difference between a class and an object
    12·1 answer
  • Many people are scared of the rise of Artificial Intelligence (AI). Do you think computers that are controlled by an AI are some
    11·2 answers
  • What option in the zone aging/scavenging properties dialog box will prevent dns record time stamps from being updated too often?
    9·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!