Algorithm Flashcards: A Study Aid for Common Algorithmic Problems

Table of Contents

1. Sorting Algorithms

1.2. Describe the basic idea of Quicksort   drill algorithm

1.2.1. Answer

  1. Choose a pivot element
  2. Partition the array around the pivot
  3. Recursively sort the subarrays

2. Searching Algorithms

2.2. Describe the basic idea of Depth-First Search (DFS)   drill algorithm

2.2.1. Answer

Explore as far as possible along each branch before backtracking

3. Graph Algorithms

3.1. What is the purpose of Dijkstra's algorithm?   drill algorithm

3.1.1. Answer

To find the shortest path between nodes in a graph

3.2. What problem does the Bellman-Ford algorithm solve?   drill algorithm

3.2.1. Answer

Finds shortest paths from a source vertex to all other vertices, even with negative edge weights

4. Dynamic Programming