answer.
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
Tems11 [23]
2 years ago
13

After performing many sequential searches on a list of 6000 entries, what would you expect to be the average number of times tha

t the target value would have been compared to a list entry? What if the search algorithm was the binary search?
Computers and Technology
2 answers:
zhannawk [14.2K]2 years ago
7 0
Hello there.
<span>
After performing many sequential searches on a list of 6000 entries, what would you expect to be the average number of times that the target value would have been compared to a list entry? What if the search algorithm was the binary search?
</span>
3000.

nordsb [41]2 years ago
5 0
<span>The worst case for searching a list of n entries sequentially is n compares (one for each entry that doesn't match). The best case is 1 compare. Sequential search is thus O(n) complexity. However, ON AVERAGE, n/2 entries have to be examined. The average of the best and worst case (1 and n) is n / 2. The second best and second worst is n / 2, etc. So, the answer is 3000. </span>
You might be interested in
We Deliver trains its truck loaders how to set the packages in the delivery vehicles, so that when delivery drivers are pulling
damaskus [11]

Answer:

We Deliver trains its truck loaders how to set the packages in the delivery vehicles, so that when delivery drivers are pulling packages off their trucks, they are organized in a specific order and with the label facing forward to reduce errors and save time. A <u>Procedure </u>is being implemented when directing that the trucks be loaded in this specific manner.

Explanation:

Procedure is the method or set of instructions to perform some operation in specific order to complete the task in an organized manner. It is the type of directions to perform some operations.

In above mentioned case, if we want that the packages should set in some organized manner such as labeling face of package in forward direction so that, chance of error should reduce and time save. We should provide some procedure to the truck loaders.

5 0
2 years ago
Which presenter would most likely benefit from a custom slide show?
PIT_PIT [208]
Which presenter would most likely benefit from a custom slide show?

a teacher who teaches four sessions of the same course
3 0
2 years ago
Read 2 more answers
In a particular jurisdiction, taxi fares consist of a base fare of $4.00, plus $0.25 for every 140 meters traveled. Write a func
devlian [24]

Answer:

// here is code in java.

import java.util.*;

// class definition

class Main

{

// method that return total fare

   public static double fare(double dis)

   {

   // calculate the total fare

       double tot_fare=(4+((dis*1000)/140)*0.25);

       return the fare

       return tot_fare;

   

   }

   //driver method

public static void main (String[] args) throws java.lang.Exception

{

   try{

    // scanner object to read input string

       Scanner s=new Scanner(System.in);

        // variable

       double dis;

       System.out.print("please enter the distance in KM: ");

       //read the number

       dis=s.nextDouble();

       

       // call the function with "dis" parameter

     double ride_fare=fare(dis);

     // print the total fare

     System.out.println("total fare is: "+ride_fare);

   }catch(Exception ex){

       return;}

}

}

Explanation:

Read the distance from user with the help of scanner class.Call the function with parameter "dis".Here it will calculate the total fare as (4+((dis*1000)/140)*0.25). Here base fare is $4 and $0.25 for every 140 meter.Then function will return the total fare.

Output:

please enter the distance in KM: 7                                                                                                                            

total fare is: 16.5  

7 0
2 years ago
Java uses interfaces to provide the benefits of multiple inheritance. A superclass object is a subclass object. A subclass is of
WITCHER [35]

COMPLETE QUESTION

Which of the following is false?

a. A subclass is often larger than its super class.

b. A super class is object is a subclass object.

c. The class following the extends keyword in a class declaration is that direct super class of the class being declared.

d. Java uses interfaces to provide the benefits of multiple inheritance

Answer:

B) A super class is object is a subclass object.

Explanation:

In object oriented programming, the concept of inheritance is greatly utilized, this refers to deriving a class from another class. The derived class is the sub-class and it is derived from its super class, as a matter of fact in Java programming language, all classes are derived from some other class. Objects are made from classes with their state (fields) and behavior (methods) since objects are made from classes, the objects of the super class will not be the same as that of the subclass.

4 0
2 years ago
To be a successful computer systems engineer, you must be proficient in programming languages and operating systems. Similarly,
Maslowich

Collectively, skills like the ones listed above are Technical skills. These skills refer to the Knowledge and ability to perform specific tasks. However, Soft skills are also important, because they relate to the ability to interact and communicate effectively with people.

6 0
2 years ago
Read 2 more answers
Other questions:
  • In three to four sentences, describe why CEOs (the chief executive officers, that is, the leaders of large companies) make very
    9·1 answer
  • What is the major function of the network access layer?
    5·1 answer
  • Catherine wants to search online for fruit juices. She is fine with aerated or fresh fruit juices. Which Boolean operator will e
    12·2 answers
  • Which of the following would be a considered a want rather than a need for most people?
    15·1 answer
  • 7. Test Average and Grade Write a program that asks the user to enter five test scores. The program should display a letter grad
    15·1 answer
  • You realize your computer has been infected with malware. It seems as if someone is controlling your computer from a remote loca
    5·1 answer
  • Define a method named roleOf that takes the name of an actor as an argument and returns that actor's role. If the actor is not i
    8·1 answer
  • Select the correct navigational path to freeze the top row of your worksheet. Select the panes you wish to freeze. Click the tab
    15·2 answers
  • What measures are needed to trace the source of various types of packets used in a DoS attack? Are some types of packets easier
    14·1 answer
  • Write a print statement that displays a random integer between 5 and 5000. Assume the random library is imported.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!