100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
C949 STUDY GUIDE QUESTIONS AND ANSWERS 2024 $18.99   Add to cart

Exam (elaborations)

C949 STUDY GUIDE QUESTIONS AND ANSWERS 2024

 10 views  0 purchase
  • Course
  • WGU C949
  • Institution
  • WGU C949

Exam of 9 pages for the course WGU C949 at WGU C949 (C949 STUDY GUIDE)

Preview 2 out of 9  pages

  • August 10, 2024
  • 9
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
  • WGU C949
  • WGU C949
avatar-seller
Dreamer252
C949 STUDY GUIDE


Linear search - answeris a search algorithm that starts from the beginning of a list, and
checks each element until the search key is found or the end of the list is reached.

An algorithm's __________is the time the algorithm takes to execute. - answerruntime

Binary search - answerfirst checks the middle element of the list. If the search key is
found, the algorithm returns the matching location. If the search key is not found, the
algorithm repeats the search on the remaining left sublist (if the search key was less
than the middle element) or the remaining right sublist (if the search key was greater
than the middle element).

___________is the process of converting a list of elements into ascending (or
descending) order. - answerSorting

_________ a sorting algorithm that treats the input as two parts, a sorted part and an
unsorted part, and repeatedly selects the proper next value to move from the unsorted
part to the end of the sorted part. - answerSelection sort

The selection sort algorithm runtime is - answerO(N2).
If a list has N elements, the outer loop executes N times. For each of those N outer loop
executions, the inner loop executes an average of N/2 times. So the total number of
comparisons is proportional to N⋅N2, or O(N2). Other sorting algorithms involve more
complex algorithms but have faster execution times.

Insertion sort - answeris a sorting algorithm that treats the input as two parts, a sorted
part and an unsorted part, and repeatedly inserts the next value from the unsorted part
into the correct location in the sorted part.

A ___________ list only contains a few elements not in sorted order. Ex: (4, 5, 17, 25,
89, 14) is nearly sorted having only one element not in sorted positio - answernearly
sorted

Shell sort - answeris a sorting algorithm that treats the input as a collection of
interleaved lists, and sorts each list individually with a variant of the insertion sort
algorithm.

A _________ is a positive integer representing the distance between elements in an
interleaved list. For each interleaved list, if an element is at index i, the next element is
at index i + gap value. - answergap value

, The______________ equals the number of times insertion_sort_interleaved() is called.
- answersum of the gap values

___________ is a sorting algorithm that repeatedly partitions the input into low and high
parts (each part unsorted), and then recursively sorts each of those parts. -
answerQuicksort

____________is a sorting algorithm that divides a list into two halves, recursively sorts
each half, and then merges the sorted halves to produce a sorted list. The recursive
partitioning continues until a list of 1 element is reached, as list of 1 element is already
sorted. - answerMerge sort

_____________ is a numerical sorting algorithm that distributes numbers into buckets,
sorts each bucket with an additional sorting algorithm, and then concatenates buckets
together to build the sorted result. - answerBucket sort

A _________ is a container for numerical values in a specific range. Ex: All numbers in
the range 0 to 49 may be stored in a bucket representing this range. Bucket sort is
designed for arrays with non-negative numbers. - answerbucket

The term "bucket sort" is sometimes used to refer to a category of ______, instead of a
specific sorting algorithm. - answersorting algorithms

_________ is a sorting algorithm designed specifically for integers. The algorithm
makes use of a concept called buckets and is a type of bucket sort. - answerRadix sort

A ______________ is a sorting algorithm that has an average runtime complexity of
O(NlogN) or better. The table below shows average runtime complexities for several
sorting algorithms. - answerfast sorting algorithm

A_______________ is a sorting algorithm that operates on an array of elements that
can be compared to each other. - answerelement comparison sorting algorithm

Python has a built-in_______function that takes one list argument, sorts the list's
elements in ascending order using the less than (<) operator, and returns a new list with
the sorted elements. - answersorted()

Python lists also have a ________method to do an in-place sorting of list elements in
ascending order, meaning the list is modified and another list is not returned. -
answersort()

A special function, _________, defined in Python's operator module, can be used to get
a key from an element using an index instead of a custom key function. Ex: key =
key_is_name can be replaced with key = operator.itemgetter(0), because the element
names are found at index 0. - answeritemgetter()

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

Guaranteed quality through customer reviews

Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.

Quick and easy check-out

Quick and easy check-out

You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

Focus on what matters

Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!

Frequently asked questions

What do I get when I buy this document?

You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.

Satisfaction guarantee: how does it work?

Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.

Who am I buying these notes from?

Stuvia is a marketplace, so you are not buying this document from us, but from seller Dreamer252. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy these notes for $18.99. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

75323 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy study notes for 14 years now

Start selling
$18.99
  • (0)
  Add to cart