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
kykrilka [37]
4 years ago
13

From the binary search algorithm, it follows that every iteration of the while loop cuts the size of the search list by half.

Computers and Technology
1 answer:
Colt1911 [192]4 years ago
6 0

Answer:

True: In binary search algorithm, we follow the below steps sequentially:

Input: A sorted array  B[1,2,...n] of n items and one item x to be searched.

Output: The index of x in B if exists in B, 0 otherwise.

  1. low=1
  2. high=n
  3. while( low < high )
  4.  {      mid=low + (high-low)/2
  5.         if( B[mid]==x)
  6.          {
  7.             return(mid)  //returns mid as the index of x
  8.           }
  9.          else
  10.          {
  11.              if( B[mid] < x)      //takes only right half of the array
  12.               {
  13.                 low=mid+1
  14.               }
  15.              else               // takes only the left half of the array
  16.               {
  17.                high=mid-1
  18.               }
  19.           }
  20.  }
  21. return( 0 )

Explanation:

For each iteration the line number 11 or line number 15 will be executed.

Both lines, cut the array size to half of it and takes as the input for next iteration.

You might be interested in
"Jan23" can be stored using which data type? O an alphanumeric string O a boolean operator o characters floating point numbers​
Delvig [45]

Answer:

Alphanumeric string

Explanation:

5 0
3 years ago
Read 2 more answers
A network administrator is required to upgrade wireless access to end users in a building. To provide data rates up to 1.3 Gb/s
matrenka [14]

Answer:

B

Explanation:

I choose b and it was correct

8 0
4 years ago
Organizations are struggling to reduce and right-size their information foot-print, using data governance techniques like data c
natka813 [3]

The effort is necessary in making sure that the data is meaningful, correct, and timely. Many analysts are increasingly focused on quality on a per-attribute basis instead of a per-report basis. This will avoid excess control of access and instead focus on meaning. A data-driven organization that includes a comprehensive data cleanup is able to make informed choices that maximize value on strategic investments.

8 0
3 years ago
PLSS HELP ASAP ILL GIVE BRAINLIEST THANKS
Margarita [4]

Answer:

span > : A generic container that can be used for styling specific portions of text.

6 0
3 years ago
In social networking websites such as twitter, people leave narrow minded and subjective remarks and upload unacceptable videos.
koban [17]
The advice is That you Message Them To remind Them Those Type of posts are not appropriate if people on social Media say bad Things To you you block Them if people don’t Treat you nice
8 0
3 years ago
Other questions:
  • Give the Division Hashing function and the index it maps the key 2000 into, assuming a primary storage area array size of 61 ele
    6·1 answer
  • What is transmission control protocol?
    9·2 answers
  • A laptop computer communicates with a router wirelessly, by means of radio signals. the router is connected by cable directly to
    10·1 answer
  • Which entity has the principal responsibility to control the execution of processes?
    14·1 answer
  • Dell Computers is a nationally recognized manufacturer of computers for the small business and home markets. If Dell were to ord
    9·1 answer
  • Given an 10-bit two's complement binary number, what is the decimal value of the largest negative integer that can be represente
    10·1 answer
  • Help, I'm a beginner in coding! I have to write a quiz. You don't have to get all fancy and stuff, since I'm a beginner lol. I w
    12·1 answer
  • The abuse of children is a symptom of
    6·2 answers
  • Why isn't image display working on wacom tablet.
    8·1 answer
  • Connection security rules are used to secure traffic between two computers while it crosses internet?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!