Docsity

Engineers Canada 19-Soft-A1 Algorithms & Data Structures Exam, Exams of Technology

Partial preview of the text

Download Engineers Canada 19-Soft-A1 Algorithms & Data Structures Exam and more Exams Technology in PDF only on Docsity!

Engineers Canada

19-Soft-A1 Algorithms &

Data Structures Exam

Question 1

Which allocation preserves the distinct technical contexts of Application to divide-and-conquer algorithm analysis, Arrays, dynamic arrays, sparse arrays, and memory layouts, and Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods)?

A. Application to divide-and-conquer algorithm analysis: Recurrence Relations; Arrays, dynamic arrays, sparse arrays, and memory layouts: Linear Data Structures; Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods): Asymptotic Analysis and Complexity Notation B. Application to divide-and-conquer algorithm analysis: Asymptotic Analysis and Complexity Notation; Arrays, dynamic arrays, sparse arrays, and memory layouts: Recurrence Relations; Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods): Linear Data Structures C. Application to divide-and-conquer algorithm analysis: Linear Data Structures; Arrays, dynamic arrays, sparse arrays, and memory layouts: Asymptotic Analysis and Complexity Notation; Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods): Recurrence Relations D. Application to divide-and-conquer algorithm analysis: Linear Data Structures; Arrays, dynamic arrays, sparse arrays, and memory layouts: Recurrence Relations; Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods): Asymptotic Analysis and Complexity Notation

Correct Answer: A

Full Explanation: Application to divide-and-conquer algorithm analysis is a specific concern within Recurrence Relations. Arrays, dynamic arrays, sparse arrays, and memory layouts is a specific concern within Linear Data Structures. Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods) is a specific concern within Asymptotic Analysis and Complexity Notation. Each concern should retain its corresponding technical context

Question 4

Which concept is most directly concerned with N-Queens?

A. Greedy Algorithms B. Advanced applications C. Classic problems D. breaking problems into independent sub-problems

Correct Answer: C

Full Explanation: Classic problems concerns N-Queens, Hamiltonian cycles, subset sum, and traveling salesperson problem (TSP). The description identifies the specific concern; the other choices address different concerns

Question 5

Which paired description correctly preserves the different emphases of Efficient sorting algorithms and Minimum spanning trees?

A. Efficient sorting algorithms: Kruskal's algorithm (using disjoint-set data structures/Union-Find) and Prim's algorithm; Minimum spanning trees: Kruskal's algorithm (using disjoint-set data structures/Union-Find) and Prim's algorithm B. Efficient sorting algorithms: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis); Minimum spanning trees: Kruskal's algorithm (using disjoint-set data structures/Union-Find) and Prim's algorithm C. Efficient sorting algorithms: Kruskal's algorithm (using disjoint-set data structures/Union-Find) and Prim's algorithm; Minimum spanning trees: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis) D. Efficient sorting algorithms: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis); Minimum spanning trees: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis)

Correct Answer: B

Full Explanation: Efficient sorting algorithms concerns Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis). Minimum spanning trees concerns Kruskal's algorithm (using disjoint-set data structures/Union-Find) and Prim's algorithm. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 6

Which assignment correctly distinguishes the concerns of Trees and Applications of network flow?

A. Trees: Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order); Applications of network flow: Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order) B. Trees: Bipartite matching and min-cut/max-flow theorem; Applications of network flow: Bipartite matching and min-cut/max-flow theorem C. Trees: Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order); Applications of network flow: Bipartite matching and min-cut/max-flow theorem D. Trees: Bipartite matching and min-cut/max-flow theorem; Applications of network flow: Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order)

Correct Answer: C

Full Explanation: Trees concerns Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order). Applications of network flow concerns Bipartite matching and min-cut/max-flow theorem. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 7

Which pairing gives an appropriate technical interpretation of both Linear Data Structures and Maximum flow problems?

A. Linear Data Structures: Ford-Fulkerson method, Edmonds-Karp algorithm, and Dinic's algorithm; Maximum flow problems: Arrays, dynamic arrays, sparse arrays, and memory layouts B. Linear Data Structures: Ford-Fulkerson method, Edmonds-Karp algorithm, and Dinic's algorithm; Maximum flow problems: Ford-Fulkerson method, Edmonds-Karp algorithm, and Dinic's algorithm C. Linear Data Structures: Arrays, dynamic arrays, sparse arrays, and memory layouts; Maximum flow problems: Ford-Fulkerson method, Edmonds-Karp algorithm, and Dinic's algorithm D. Linear Data Structures: Arrays, dynamic arrays, sparse arrays, and memory layouts; Maximum flow problems: Arrays, dynamic arrays, sparse arrays, and memory layouts

Correct Answer: C

Full Explanation: Arrays, dynamic arrays, sparse arrays, and memory layouts is a specific concern within Linear Data Structures. Maximum flow problems concerns Ford-Fulkerson method, Edmonds-Karp algorithm, and Dinic's algorithm. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 9

Which allocation preserves the distinct technical contexts of Arrays, dynamic arrays, sparse arrays, and memory layouts, Greedy-choice property and proof techniques, and Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques?

A. Arrays, dynamic arrays, sparse arrays, and memory layouts: Greedy Algorithms; Greedy-choice property and proof techniques: Asymptotic Analysis and Complexity Notation; Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques: Linear Data Structures B. Arrays, dynamic arrays, sparse arrays, and memory layouts: Greedy Algorithms; Greedy-choice property and proof techniques: Linear Data Structures; Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques: Asymptotic Analysis and Complexity Notation C. Arrays, dynamic arrays, sparse arrays, and memory layouts: Linear Data Structures; Greedy-choice property and proof techniques: Greedy Algorithms; Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques: Asymptotic Analysis and Complexity Notation D. Arrays, dynamic arrays, sparse arrays, and memory layouts: Asymptotic Analysis and Complexity Notation; Greedy-choice property and proof techniques: Linear Data Structures; Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques: Greedy Algorithms

Correct Answer: C

Full Explanation: Arrays, dynamic arrays, sparse arrays, and memory layouts is a specific concern within Linear Data Structures. Greedy-choice property and proof techniques is a specific concern within Greedy Algorithms. Big-O, Big-Omega, and Big-Theta notations; formal definitions and mathematical proof techniques is a specific concern within Asymptotic Analysis and Complexity Notation. Each concern should retain its corresponding technical context

Question 10

An explanation confuses Asymptotic Analysis and Complexity Notation with Singly linked lists. Which replacement statement restores their respective focuses?

A. Asymptotic Analysis and Complexity Notation: doubly linked lists, circular linked lists and pointer manipulation and overhead; Alongside Singly linked lists within Linear Data Structures: Analyzing time complexity and space complexity of iterative and recursive algorithms B. Asymptotic Analysis and Complexity Notation: Analyzing time complexity and space complexity of iterative and recursive algorithms; Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead C. Asymptotic Analysis and Complexity Notation: doubly linked lists, circular linked lists and pointer manipulation and overhead; Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead D. Asymptotic Analysis and Complexity Notation: Analyzing time complexity and space complexity of iterative and recursive algorithms; Alongside Singly linked lists within Linear Data Structures: Analyzing time complexity and space complexity of iterative and recursive algorithms

Correct Answer: B

Full Explanation: Analyzing time complexity and space complexity of iterative and recursive algorithms is a specific concern within Asymptotic Analysis and Complexity Notation. Singly linked lists is considered together with doubly linked lists, circular linked lists and pointer manipulation and overhead in Linear Data Structures. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 11

Which paired description correctly preserves the different emphases of Elementary sorting algorithms and Searching and Selection?

A. Elementary sorting algorithms: Linear search and binary search algorithms on sorted structures; Searching and Selection: Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis) B. Elementary sorting algorithms: Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis); Searching and Selection: Linear search and binary search algorithms on sorted structures C. Elementary sorting algorithms: Linear search and binary search algorithms on sorted structures; Searching and Selection: Linear search and binary search algorithms on sorted structures D. Elementary sorting algorithms: Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis); Searching and Selection: Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis)

Correct Answer: B

Full Explanation: Elementary sorting algorithms concerns Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis). Linear search and binary search algorithms on sorted structures is a specific concern within Searching and Selection. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 14

Which paired description correctly preserves the different emphases of Singly linked lists and Linear-time sorting algorithms?

A. Alongside Singly linked lists within Linear Data Structures: Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)); Linear-time sorting algorithms: Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)) B. Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead; Linear-time sorting algorithms: Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)) C. Alongside Singly linked lists within Linear Data Structures: Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)); Linear-time sorting algorithms: doubly linked lists, circular linked lists and pointer manipulation and overhead D. Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead; Linear-time sorting algorithms: doubly linked lists, circular linked lists and pointer manipulation and overhead

Correct Answer: B

Full Explanation: Singly linked lists is considered together with doubly linked lists, circular linked lists and pointer manipulation and overhead in Linear Data Structures. Linear-time sorting algorithms concerns Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)). Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 15

An assessment is specifically about full and complete binary trees. Which heading best identifies its technical focus?

A. Trees B. Linear Data Structures C. Stacks and queues D. Singly linked lists

Correct Answer: A

Full Explanation: Trees concerns Binary trees, full and complete binary trees, binary search trees (BSTs), and tree traversal algorithms (pre-order, in-order, post-order, level-order). The description identifies the specific concern; the other choices address different concerns

Question 16

An explanation confuses Asymptotic Analysis and Complexity Notation with Applications of network flow. Which replacement statement restores their respective focuses?

A. Asymptotic Analysis and Complexity Notation: Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods); Applications of network flow: Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods) B. Asymptotic Analysis and Complexity Notation: Bipartite matching and min-cut/max-flow theorem; Applications of network flow: Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods) C. Asymptotic Analysis and Complexity Notation: Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods); Applications of network flow: Bipartite matching and min-cut/max-flow theorem D. Asymptotic Analysis and Complexity Notation: Bipartite matching and min-cut/max-flow theorem; Applications of network flow: Bipartite matching and min-cut/max-flow theorem

Correct Answer: C

Full Explanation: Best-case, worst-case, and average-case performance analysis; amortized analysis techniques (aggregate, accounting, and potential methods) is a specific concern within Asymptotic Analysis and Complexity Notation. Applications of network flow concerns Bipartite matching and min-cut/max-flow theorem. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 18

An explanation confuses Recurrence Relations with Classic problems. Which replacement statement restores their respective focuses?

A. Recurrence Relations: Application to divide-and-conquer algorithm analysis; Classic problems: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change B. Recurrence Relations: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change; Classic problems: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change C. Recurrence Relations: Application to divide-and-conquer algorithm analysis; Classic problems: Application to divide-and-conquer algorithm analysis D. Recurrence Relations: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change; Classic problems: Application to divide-and-conquer algorithm analysis

Correct Answer: A

Full Explanation: Application to divide-and-conquer algorithm analysis is a specific concern within Recurrence Relations. Classic problems concerns 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 19

A reviewer separates Singly linked lists from Directed and undirected graphs. Which allocation of issues is consistent with that distinction?

A. Alongside Singly linked lists within Linear Data Structures: weighted and unweighted graphs and representations via adjacency matrices and adjacency lists; Alongside Directed and undirected graphs within Graph Representations and Traversals: doubly linked lists, circular linked lists and pointer manipulation and overhead B. Alongside Singly linked lists within Linear Data Structures: weighted and unweighted graphs and representations via adjacency matrices and adjacency lists; Alongside Directed and undirected graphs within Graph Representations and Traversals: weighted and unweighted graphs and representations via adjacency matrices and adjacency lists C. Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead; Alongside Directed and undirected graphs within Graph Representations and Traversals: weighted and unweighted graphs and representations via adjacency matrices and adjacency lists D. Alongside Singly linked lists within Linear Data Structures: doubly linked lists, circular linked lists and pointer manipulation and overhead; Alongside Directed and undirected graphs within Graph Representations and Traversals: doubly linked lists, circular linked lists and pointer manipulation and overhead

Correct Answer: C

Full Explanation: Singly linked lists is considered together with doubly linked lists, circular linked lists and pointer manipulation and overhead in Linear Data Structures. Directed and undirected graphs is considered together with weighted and unweighted graphs and representations via adjacency matrices and adjacency lists in Graph Representations and Traversals. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 22

A technical review must address Floyd-Warshall algorithm and Johnson's algorithm. Which focus most directly fits that requirement?

A. All-pairs shortest paths B. Minimum spanning trees C. Applications of network flow D. Single-source shortest paths

Correct Answer: A

Full Explanation: All-pairs shortest paths concerns Floyd-Warshall algorithm and Johnson's algorithm. The description identifies the specific concern; the other choices address different concerns

Question 23

Which paired description correctly preserves the different emphases of Classic problems and Greedy Algorithms?

A. Classic problems: Greedy-choice property and proof techniques; Greedy Algorithms: Greedy-choice property and proof techniques B. Classic problems: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change; Greedy Algorithms: Greedy-choice property and proof techniques C. Classic problems: Greedy-choice property and proof techniques; Greedy Algorithms: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change D. Classic problems: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change; Greedy Algorithms: 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change

Correct Answer: B

Full Explanation: Classic problems concerns 0/1 and fractional knapsack, longest common subsequence (LCS), matrix chain multiplication, edit distance, and coin change. Greedy-choice property and proof techniques is a specific concern within Greedy Algorithms. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 24

When separating the specific concerns of Linear-time sorting algorithms and Selection algorithms, which proposed pairing interchanges those concerns?

A. Linear-time sorting algorithms: Finding the i-th order statistic, randomized selection, and deterministic median-of-medians algorithm in worst-case linear time B. Elementary sorting algorithms: Bubble sort, selection sort, and insertion sort (mechanics and O(n^2) analysis) C. Searching and Selection: Linear search and binary search algorithms on sorted structures D. Efficient sorting algorithms: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis)

Correct Answer: A

Full Explanation: Linear-time sorting algorithms concerns Counting sort, radix sort, and bucket sort; lower-bound proofs for comparison-based sorting (O(n log n)). Selection algorithms concerns Finding the i-th order statistic, randomized selection, and deterministic median-of-medians algorithm in worst-case linear time. Assigning the concern of Selection algorithms to Linear-time sorting algorithms interchanges their technical emphases

Question 26

Which paired description correctly preserves the different emphases of Efficient sorting algorithms and Classic problems?

A. Efficient sorting algorithms: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis); Classic problems: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis) B. Efficient sorting algorithms: Activity selection, Huffman coding, fractional knapsack, and Dijkstra's shortest path; Classic problems: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis) C. Efficient sorting algorithms: Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis); Classic problems: Activity selection, Huffman coding, fractional knapsack, and Dijkstra's shortest path D. Efficient sorting algorithms: Activity selection, Huffman coding, fractional knapsack, and Dijkstra's shortest path; Classic problems: Activity selection, Huffman coding, fractional knapsack, and Dijkstra's shortest path

Correct Answer: C

Full Explanation: Efficient sorting algorithms concerns Merge sort, quicksort (partitioning schemes, pivot selection), heapsort, and shell sort (O(n log n) analysis). Classic problems concerns Activity selection, Huffman coding, fractional knapsack, and Dijkstra's shortest path. Keeping the two concerns attached to their respective concepts avoids a mistaken interchange

Question 27

Which paired description correctly preserves the different emphases of optimal substructure and overlapping subproblems and Complexity theory foundations?

A. Alongside optimal substructure and overlapping subproblems within Dynamic Programming: memoization vs. tabulation; Complexity theory foundations: memoization vs. tabulation B. Alongside optimal substructure and overlapping subproblems within Dynamic Programming: Classes P, NP, NP-complete, and NP-hard; polynomial-time reductions and classic NP-complete problems (SAT, 3-SAT, Vertex Cover, Clique); Complexity theory foundations: memoization vs. tabulation C. Alongside optimal substructure and overlapping subproblems within Dynamic Programming: memoization vs. tabulation; Complexity theory foundations: Classes P, NP, NP-complete, and NP-hard; polynomial-time reductions and classic NP-complete problems (SAT, 3-SAT, Vertex Cover, Clique) D. Alongside optimal substructure and overlapping subproblems within Dynamic Programming: Classes P, NP, NP-complete, and NP-hard; polynomial-time reductions and classic NP-complete problems (SAT, 3-SAT, Vertex Cover, Clique); Complexity theory foundations: Classes P, NP, NP-complete, and NP-hard; polynomial-time reductions and classic NP-complete problems (SAT, 3-SAT, Vertex Cover, Clique)

Correct Answer: C

Full Explanation: optimal substructure and overlapping subproblems is considered together with memoization vs. tabulation in Dynamic Programming. Complexity theory foundations concerns Classes P, NP, NP-complete, and NP-hard; polynomial-time reductions and classic NP-complete problems (SAT, 3-SAT, Vertex Cover, Clique). Keeping the two concerns attached to their respective concepts avoids a mistaken interchange