Log In
Start
Free
Trial
Log In
Start
Free
Trial
Back To Course Home
Algorithms for Coding Interviews in C++
0% completed
Introduction
Who This Course Is For
Learning Outcomes
Algorithmic Paradigms
Brute Force
Greedy Algorithms
Divide and Conquer
Dynamic Programming
Introduction to Complexity Measures
Comparing Algorithms
Example 1: Measuring Time Complexity of a Single Loop Algorithm
Example 2: Time Complexity of an Algorithm With Nested Loops
Introduction to Asymptotic Analysis and Big O
Other Common Asymptotic Notations and Why Big O Trumps Them
Useful Formulae
Common Complexity Scenarios
Challenge 1: Big (O) of Nested Loop with Addition
Solution Review: Big (O) of Nested Loop with Addition
Challenge 2: Big (O) of Nested Loop with Subtraction
Solution Review: Big (O) of Nested Loop with Subtraction
Challenge 3: Big (O) of Nested Loop with Multiplication
Solution Review: Big (O) of Nested Loop with Multiplication
Challenge 4: Nested Loop with Multiplication (Basic)
Solution Review: Nested Loop with Multiplication (Basic)
Challenge 5: Nested Loop with Multiplication (Intermediate)
Solution Review: Nested Loop with Multiplication (Intermediate)
Challenge 6: Nested Loop with Multiplication (Advanced)
Solution Review: Nested Loop with Multiplication (Advanced)
Challenge 7: Nested Loop with Multiplication (Pro)
Solution Review: Nested Loop with Multiplication (Pro)
Complexity Quiz: Test your understanding of Complexity
Sorting & Searching
Selection Sort, Bubble Sort, & Insertion Sort
Merge Sort
Quicksort
Overview of Sorting Algorithms
Searching Algorithms
Challenge 1: Find Two Numbers that Add up to "s"
Solution Review: Find Two Numbers that Add up to "s"
Challenge 2: Search in a Rotated Array
Solution Review: Search in a Rotated Array
Challenge 3: Group Anagrams
Solution Review: Group Anagrams
Challenge 4: Find the Median of Two Sorted Arrays
Solution Review: Find the Median of Two Sorted Arrays
Challenge 5: Find Duplicates in Array
Solution Review: Find Duplicates in Array
Challenge 6: Search in Sorted Matrix
Solution Review: Search in Sorted Matrix
Challenge 7: Count Element Occurrence
Solution Review: Count Element Occurrence
Challenge 8: Search Insert Position
Solution Review: Search Insert Position
Challenge 9: Sparse Search
Solution Review: Sparse Search
Challenge 10: Dutch National Flag Problem
Solution Review: Dutch National Flag Problem
Quiz on Sorting & Searching
Graph Algorithms
Introduction to Graph Algorithms and Implementation
Challenge 1: Implement Breadth First Graph Traversal
Solution Review: Breadth First Graph Traversal
Challenge 2: Implement Depth First Graph Traversal
Solution Review: Depth First Graph Traversal
Challenge 3: Calculate the Number of Nodes in a Given Graph Level
Solution Review: Calculate the Number of Nodes in a Given Graph Level
Challenge 4: Print the Transpose of a Graph
Solution Review: Print the Transpose of a Graph
Challenge 5: Print all Paths Between Two Nodes
Solution Review: Print all Paths Between Two Nodes
Challenge 6: Check If Graph is Strongly Connected
Solution Review: Check if a Graph is Strongly Connected
Challenge 7: Print all Connected Components in a Graph
Solution Review: Print all Connected Components of a Graph
Challenge 8: Check if Removing Edge Creates Components in Graph
Solution Review: Check if Removing Given Edge Creates Components in Graph
Challenge 9: Check If Given Graph is Bipartite
Solution Review: Check If Given Graph is Bipartite
Challenge 10: Topological Sorting of a Graph
Solution Review: Topological Sorting of a Graph
Quiz on Graph Algorithms
Greedy Algorithms
Activity Scheduling Problem
Challenge 1: Counting Money!
Solution Review: Counting Money
Challenge 2: Connecting n pipes with minimum cost
Solution Review: Connecting n pipes with minimum cost
Challenge 3: Find the Egyptian Fraction
Solution Review: Find the Egyptian Fraction
Challenge 4: Find Minimum Number of Platforms Required for a Train Station
Solution Review: Find Minimum Number of Platforms Required for a Train Station
Challenge 5: Help the Policemen Catch the thieves!
Solution Review: Help the Policemen Catch the thieves!
Challenge 6: Fractional Knapsack Problem
Solution Review: Fractional Knapsack Problem
Challenge 7: Largest Number with Given Number of Digits and Sum of Digits
Solution Review: Largest Number with Given Number of Digits and Sum of Digits
Challenge 8: Graph Coloring
Solution Review: Graph Coloring
Challenge 9: Find the Minimum Spanning Tree of the Given Graph
Solution Review: Kruskal’s Solution to Minimum Spanning Tree
Solution Review: Prim's Solution to Minimum Spanning Trees
Challenge 10: Find Shortest Distance of Each Node from the Source
Solution Review: Shortest Distance of Each Node from the Source
Quiz on Greedy Algorithms
Dynamic Programming
Calculating Fibonnacci Numbers
Introducing Dynamic Programming With Fibonacci Numbers
Memoizing Fibonacci Numbers
Tabulating Fibonacci Numbers
Challenge 1: The 0/1 Knapsack Problem
Solution Review: The 0/1 Knapsack Problem
Challenge 2: Staircase Problem
Solution Review: Staircase Problem
Challenge 3: The Partition Problem
Solution Review: The Partition Problem
Challenge 4: Longest Common Substring
Solution Review: Longest Common Substring
Challenge 5: Shortest Common Supersequence
Solution Review: Shortest Common Supersequence
Challenge 6: Longest Palindromic Subsequence
Solution Review: Longest Palindromic Subsequence
Challenge 7: The Coin Change Problem
Solution Review: Coin Change Problem
Challenge 8: Egg Dropping Problem
Solution Review: Egg Dropping Problem
Challenge 9: Strings Interleaving
Solution Review: Strings Interleaving
Challenge 10: Edit Distance Problem
Solution Review: The Edit Distance Problem
Quiz on Dynamic Programming
Divide and Conquer
Introduction to Divide and Conquer with Binary Search
Pascal's Triangle
Challenge 1: Euclidean Algorithm
Solution Review: Euclidean Algorithm
Challenge 2: Peak Element
Solution Review: Peak Element
Challenge 3: Maximum Subarray Sum
Solution Review: Maximum Subarray Sum
Challenge 4: Merge a Number of Sorted Arrays
Solution Review: Merge a Number of Sorted Arrays
Challenge 5: Collect Coins in Minimum Steps
Solution Review: Collect Coins in Minimum Steps
Challenge 6: Find The Closest Number
Solution Review: Find Closest Number
Challenge 7: Closest Pair of Points
Solution Review: Closest Pair of Points
Challenge 8: Missing Number in Sorted Array
Solution Review: Missing Number in Sorted Array
Challenge 9: Binary Search on Singly Linked List
Solution Review: Binary Search on Singly Linked List
Challenge 10: Shuffle Integers
Solution Review: Shuffle Integers
Quiz on Divide and Conquer
Appendix: Auxiliary Source Code
STL Classes
Linked List
Array Functions
Graph
Conclusion
Overview
Where to Go from Here
Solution Review: Egg Dropping Problem
We'll cover the following
Solution #1: Brute Force
Pseudocode
Solution #2: Memoization
Solution #3: Tabularization
Time Complexity
Solution #4: Using Binomial Coefficient and Search Solution
Time Complexity
Solution #1: Brute Force
#
Level up your interview prep. Join Educative to access 80+ hands-on prep courses.
Start Free Trial