How many passes will it take to find 12 using a binary search? 8, 10, 12, 14, 16, 18, 20
1 3 4 2

Answers

Answer 1

Answer:

3 passes

Explanation:

Binary search halves and halves an ordered list of numbers until the value being searched is found.

14 is the middle number. it is larger than 12 so we look at the left side

10 is the middle number of the left side it is smaller than 12 os we look at the right side

12 is the middle number between 10 and 14 and it is also the number we are trying to find.


Related Questions

Columns are identified by numbers (1,2,3,4,5....) and Rows are identified by letters (A,B,C,D,E.....) True False

Answers

The answer would be true. Hope this helps you

Low-level programming languages are (5 points)
a
closer to human languages
Ob
less readable by humans
O
C
more readable by humans
Od
written in human languages

Answers

Answer:

Low-level programming languages are essentially written as the computer interprets them (examples would be assembly and machine language), so the answer is B.

Explanation:

You are the network administrator for a city library. Throughout the library, there are several groups of computers that provide public access to the internet. Supervision of these computers has been difficult. You've had problems with patrons bringing personal laptops into the library and disconnecting the network cables from the library computers to connect their laptops to the internet. The library computers are in groups of four. Each group of four computers is connected to a hub that is connected to the library network through an access port on a switch. You want to restrict access to the network so only the library computers are permitted connectivity to the internet. What can you do to fix this problem

Answers

Answer: Configure port security on the switch

Explanation:

Since there need to be a restriction on access to the network so that the library computers will be the only ones that are allowed connectivity to the internet, the thing that can be done to fix the problem is to configure a port security on the switch.

When a port security is configured, it helps in securing the network and this will in the prevention of unknown devices from being connected to the network.

9.6 Code practice Edhesive

Answers

Answer:

N = [1,1,1,1,1],

[2,2,2,2,2],

[3,3,3,3,3],

[4,4,4,4,4]

def printIt(ar):

   for row in range(len(ar)):

       for col in range(len(ar[0])):

           print(ar[row][col], end=" ")

       print("")

           

N=[]

for r in range(4):

   N.append([])

   

for r in range(len(N)):

   value=1

   for c in range(5):

       N[r].append(value)

       value=value + 1

           

printIt(N)

print("")

newValue=1

for r in range (len(N)):

   for c in range(len(N[0])):

       N[r][c] = newValue

   newValue = newValue + 1

       

printIt(N)

Explanation:

I got 100%.

In this exercise we have to use the knowledge of computational language in python to write the code.

We have the code in the attached image.

The code in python can be found as:

def printIt(ar):

  for row in range(len(ar)):

      for col in range(len(ar[0])):

          print(ar[row][col], end=" ")

      print("")        

N = [1,1,1,1,1], [2,2,2,2,2], [3,3,3,3,3], [4,4,4,4,4]

for r in range(4):

  N.append([])

for r in range(len(N)):

  value=1

  for c in range(5):

      N[r].append(value)

      value=value + 1

printIt(N)

print("")

newValue=1

for r in range (len(N)):

  for c in range(len(N[0])):

      N[r][c] = newValue

  newValue = newValue + 1

printIt(N)

See more about python at brainly.com/question/26104476

also have a good day people !!

Answers

Answer:

Thx u2!!

Explanation:

Everyone have a good day!

Answer:

You too and thank you for 50 points!!

Explanation:

Two parter:

A.) What is wrong with the program segment below? The program does not contain syntax errors.

B.) Fix the programming error(s)

num = 1;

while (num < 9)
{
cout << num;
num = num - 1;
}

Answers

Answer:

the variable num is not declared so the compiler doesn't define it.

add int before num:

int num = 1;

while (num < 9)

{

cout << num;

num = num - 1;

}

now the code will run but it won't stop as it will never break the condition (num < 9).

Match the roles to the task they perform.

gather requirements
create software framework
identify errors in the software
develop program code for software

Role

software architects
business analysts
programmers
testers

Answers

Software Architects: “develop program code for software”

Business Analysts: “gather requirements”

Programmers: “create software framework”

Testers: “identify errors in the software”

In python please!! Write the definition of a function named countPos that needs integer values from standard input until there are none left and returns the number that are positive. The function must not use a loop of any kind.

Answers

Answer:

Explanation:

The following code is written in Python it doesn't use any loops, instead it uses a recursive function in order to continue asking the user for the inputs and count the number of positive values. If anything other than a number is passed it automatically ends the program.

def countPos(number=input("Enter number: "), counter=0):

   try:

       number = int(number)

       if number > 0:

           counter += 1

           newNumber = input("Enter number: ")

           return countPos(newNumber, counter)

       else:

           newNumber = input("Enter number: ")

           return countPos(newNumber, counter)

   except:

       print(counter)

       print("Program Finished")

countPos()

What is the difference between electrical and electronic devices?

Answers

Answer:

A difference is that the electrical devices makes the electrical energy into the other forms of energies, such as heat, light, sound, gravitational, and nuclear. . . The electronic device controls the flow of electrons for performing the task.

Answer:

the different between electrical and electronics devices is the electricity and the power of inside of some devices which are considered most powerful electronics from, because the difference is the battery.

Explanation:

i hope it helps ;)

List two examples of following types of communication

Answers

Verbal Communication. Verbal communication occurs when we engage in speaking with others. ...
Non-Verbal Communication. What we do while we speak often says more than the actual words. ...

Answer:

Explanation:

sign language is communication

touch is communication

You are part of a testing team at a software business. Your job is to see how many concurrent users the system can host and how many database transactions the system can handle without a noticeable drop in performance. You are doing _____ testing. a. acceptance testing b. volume testing c. system testing d. integration testing

Answers

Answer:

The right approach is Option b (volume testing).

Explanation:

A non-functional trial that has been conducted throughout a results evaluation where even a large amount of information becomes accessible to something like the program, would be determined as Volume testing.The application functionality has been analyzed by determining the maximum volume throughout the database.

Other options are not related to the given query. So the above is the right response.

_______________is the career cluster that medical professionals are under.

Answers

I think the answer is Doctor ?

Match each operating system drawback to its respective operating system.

1. more susceptible to viruses Linux. Operating System
2. fewer compatible applications Microsoft Windows Operating System
3. limited support system Apple Operating System

Answers

Answer:

Microsoft Windows - More susceptible to viruses

Linux - Limited support system

Apple - Fewer compatible applications

Explanation:

Generally windows is more susceptible to viruses.

Linux is open source meaning it's up to the community to help you.

Apple has been supporting more applications in these coming years but it still lacks the wide range of apps windows supports.

Answer:

1. Microsoft Windows is more susceptible to viruses

2. Mac OS X (Apple OS) has fewer compatible applications

3. Linux OS has a limited support system.


what is the answer???​

Answers

Answer:

I think it should be C

Explanation:

A group of two or more computers that are link together.

how important the role of valet and butler service in the hospitality

Answers

very important bc they help you with what you need.

Three types of common program errors are syntax, runtime, and logic. (5 points)
O True
O False

Answers

Answer:

True

Explanation:

True,My good sir/maam

Type the correct answer in the box. Spell all words correctly.
Alan maintains the efficiency of a printing plant by supervising plant operations and implementing safety procedures. What does he work as?
Alan is working as a _____________.

Answers

Answer:

Alan is a Maintenance Supervisor.

Explanation:

Answer:

printing plant manager

Explanation:

Hardware failure, power outages, and DOS attacks will affect:

data confidentiality.

data integrity.

data verification.

data availability.

Answers

Answer:

The answer should be data availability

Drag the tiles to the correct boxes to compete the pairs. Identify the types of chemical reactions occurring in the chemical equations.

Answers

The question is incomplete. The complete question is :

Drag the tiles to the correct boxes to compete the pairs. Identify the types of chemical reactions occurring in the chemical equations.

combustion reaction , photosynthesis , respiration

water + carbon dioxide + sunlight → oxygen + glucose

methane + oxygen → water + carbon dioxide + heat

glucose + oxygen → carbon dioxide + water + energy

Solution :

The chemical reactions that is occurring in the following chemical equations are :

Photosynthesis

water + carbon dioxide + sunlight → oxygen + glucose

Plants uses the light energy from the sun in the presence of water and carbon dioxide produces food by the process of photosynthesis. It produces glucose and oxygen.

Respiration

glucose + oxygen → carbon dioxide + water + energy

The cellular respiration process produces ATP with the breakdown of the glucose and oxygen. During respiration process, carbon dioxide is obtained along with water and energy.

Combustion reaction

methane + oxygen → water + carbon dioxide + heat

Combustion reaction is a chemical reaction in which methane is the main ingredient. Combustion takes place as things burn in the presence to methane and oxygen to form carbon dioxide, water and heat.

Other Questions
Sara invested a total of $1,014 by purchasing shares of two types of stock, stock A and stock B. she purchased 52 shares of stock A and 65 shares of stock B. if the combined cost for one share of stock A and one share of stock B is $17.18 find the cost per share of stock B Como leer el decimal 0.000000215 A television selling for $940.00 is marked down by 15%. What is the price after the markdown? Look at the map of Europe. A map of western Europe. The following countries are labeled: Kingdom of Scotland, Kingdom of England (which includes western half of modern France), Kingdom of France, Kingdom of Navarre, Holy Roman Empire, Kingdom of Denmark. Which of the following would be the best title for the map? The Roman Empire Europe after the Norman Conquest The Holy Roman Empire The First Crusade Five friends shared 1 1/2 pounds of fudge equally. How much did each friend get? of the following are abiotic factors in an ecosystem except _______.Select one:a.types of mineralsb.ocean currentsc.types of bacteriad.temperature What are the expectations that are hoped to be realized once they have entered the US? Please answer A 1.50x103-kilogram car is traveling east at 30 meters per second.The brakes are applied and the car is brought to rest in 9.00 seconds.A. Calculate the magnitude of the total impulse applied to the car tobring it to rest. [Show all work, including the equation andsubstitution with units.]B. State the direction of the impulse applied to the car. [East orWest?]PLEASE HELP!!!! give at least 2 objects that have the shape of triangle.give at least 3 objects that have the shape of quadrilateral. How does the conversation with her grandmother inparagraph 17 affect Noor? Use details from the story in youranswer. What is the quality of the third chord in every Major key?A.AugmentedB.MajorC.DiminishedD.Minor HELP!!!! URGENT!!!!The following question has two parts. First, answer Part A. Then, answer Part B. Part AWhat is the meaning of the phrase swallowed the bait as it is used in this sentence from The Humbugs of the World? "I was ready to burst with laughter to see how readily Adams swallowed the bait, but maintaining the most rigid gravity, I replied." (paragraph 9)A. changed one's mind B. made up a storyC. got unusually excited about something D. believed something that wasn't truePart B What does Barnum's use of the phrase swallowed the bait suggest about how he views Adams? A. He thinks Adams is easily fooled. B. He thinks Adams looks hungry. C. He thinks Adams is greedy. D. He thinks Adams is annoying. PLEASE HELP!! I don't really know how to solve this. Plz help me well mark brainliest if you are correct!! Maleah turned on the water in the kitchen. For every 1 3/4 minute, 1 2/3 gallons of water went into the sink. How many gallons of water filled the sink per minute? WILL GIVE BRAINLIEST (URGENT) whats the circumference? How do you break apart the factor 627 using place value? please help 18 MATH PROBLEM What is the average time it takes to transport a wounded soldier back to the United States? Why does it take longer to get a soldier home than it would to just fly to a war zone in a plane?