Exam 11: Searching Sorting and Complexity Analysis

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

Algorithms describe processes that run on real computers with finite resources.

(True/False)
4.9/5
(39)

The time() function of the time module can be used to track the running time of a program.

(True/False)
4.8/5
(36)

What statement accurately describes the strategy utilized by the insertion sort algorithm?

(Multiple Choice)
4.7/5
(35)

A binary search is necessary for data that are not arranged in any particular order.

(True/False)
4.8/5
(35)

In general, we worry more about average and best-case performances than about worst-case performances.

(True/False)
4.8/5
(32)

Some algorithms require more memory as the problem size gets larger.

(True/False)
4.9/5
(41)

When you count instructions to estimate the efficiency of an algorithm, you count the instructions in the executable machine language program.

(True/False)
4.9/5
(33)

Python's in operator is implemented as a method by what name in the list class?

(Multiple Choice)
4.8/5
(26)

Sequential search is also called polynomial search.

(True/False)
4.8/5
(43)

An algorithm coded in Python usually runs slightly faster than the same algorithm coded in C.

(True/False)
4.9/5
(37)

Whenever the amount of work of an algorithm is expressed as a polynomial, we focus on one term as dominant.

(True/False)
4.9/5
(36)

What is NOT one of the three Python functions that are associated with the merge sort algorithm?

(Multiple Choice)
4.8/5
(35)

The process of determining the running time and memory cost of an algorithm by reading the code and creating a mathematical formula expressing this cost is known by what term?

(Multiple Choice)
4.9/5
(33)

What are the two major problems with the benchmark technique of measuring algorithm efficiency?

(Multiple Choice)
4.8/5
(39)

What statement accurately describes the strategy utilized by the bubble sort algorithm?

(Multiple Choice)
4.8/5
(34)

Bubble sort's worst-case behavior for exchanges is greater than linear.

(True/False)
4.9/5
(41)

What programming technique involves saving intermediate values when they are computed so they can be reused when they are needed again?

(Multiple Choice)
4.9/5
(40)

The constant of proportionality involves the terms and coefficients that are usually ignored during big-O analysis.

(True/False)
4.8/5
(34)

The first two numbers in the Fibonacci sequence are 1 and 2.

(True/False)
4.8/5
(38)

Algorithms with linear behavior do less work than algorithms with quadratic behavior for most problem sizes n.

(True/False)
4.8/5
(39)
Showing 21 - 40 of 51
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)