Algorithm Explorer: Basic Problem Solving Audio Quiz Quiz

  1. Sorting Algorithms

    Which sorting algorithm repeatedly finds the minimum element from the unsorted part and puts it at the beginning of the array?

    1. Selection sort
    2. Insertion sort
    3. Bubble sort
    4. Quick sort
    5. Section sort
  2. Binary Search

    What is the time complexity of binary search on a sorted array of size n?

    1. O(log n)
    2. O(n log n)
    3. O(n)
    4. O(1)
    5. O(n^2)
  3. Stack Operations

    Which data structure uses last-in, first-out, or LIFO, order for inserting and removing elements?

    1. Stack
    2. Queue
    3. Arrray
    4. Linklist
    5. Deque
  4. Queue Functionality

    In a standard queue, which operation removes the item that has been inside the queue the longest?

    1. Dequeue
    2. Enqueue
    3. Push
    4. Insert
    5. Dequque
  5. Bubble Sort Insight

    If an array is already sorted, how many swaps does Bubble Sort perform?

    1. Zero
    2. One
    3. n minus one
    4. n squared
    5. All
  6. Find the Output

    What is the output of this code snippet: print(sorted([3,1,4,2]))?

    1. [1, 2, 3, 4]
    2. [4, 3, 2, 1]
    3. [3, 1, 4, 2]
    4. [2, 4, 3, 1]
    5. [1, 3, 2, 4]
  7. Algorithmic Searching

    Which algorithm checks each item in a list sequentially until it finds the target value?

    1. Linear search
    2. Binary search
    3. Binery search
    4. Hash search
    5. Stack search
  8. Big O Notation

    What is the time complexity of inserting an element at the end of a Python list?

    1. O(1)
    2. O(n)
    3. O(n log n)
    4. O(n^2)
    5. O(log n)
  9. Data Structure Basics

    Which data structure is best for implementing an undo feature in text editors?

    1. Stack
    2. Queue
    3. Dack
    4. Tree
    5. Array
  10. Queue Usage

    When simulating a line of people at a checkout counter, which data structure best models this scenario?

    1. Queue
    2. Stack
    3. Tree
    4. Arrray
    5. Graph