Coursera - Algorithms Part - 2
https://www.coursera.org/learn/algorithms-part2
https://github.com/deepaksood619/Coursera-Algorithms-Part-2
Week - 1
Undirected Graph
-
Introduction to graph
- Adjacency Matrix
- Adjacency List
-
Graph API
-
Depth-First Search
-
Breadth-First Search
-
Connected Components
-
Graph Challenges
Directed Graph
-
Introduction to Digraphs
-
Digraph API
-
Digraph Search
-
Topological Sort
- Topological order of an acyclic digraph
-
Strong Components
- Kosaraju-Sharir algorithm for computing strong components of a digraph
-
Applications
- Garbage Collection
- Web Crawling
Assignment
WordNet
Week - 2
Minimum Spanning Tree
- Introduction to MSTs
- Greedy Algorithms
- Edge-Weighted Graph API
- Kruskal's Algorithm
- Prim's Algorithm
- MST Context
Shortest Path
- Shortest Path APIs
- Shortest Path Properties
- Dijkstra's Algorithm
- Edge-Weighted DAGs
- Negative Weights (Bellman Ford Algorithm)
Assignment
Seam Carving
Week - 3
Maximum Flow and Minimum Cut
- Introduction to Maxflow
- Ford-Fulkerson Algorithm
- Maxflow-Mincut Theorem
- Running Time Analysis
- Java Implementation
- Maxflow Applications
Assignment
Baseball Elimination
Radix Sorts
- Strings in Java
- Key-Indexed Counting
- LSD Radix Sort
- MSD Radix Sort
- 3-way Radix Quicksort
- Suffix Arrays
Week - 4
Tries
- R-way Tries
- Ternary Search Tries
- Character-Based Operations
Substring Search
- Introduction to Substring Search
- Brute-Force Substring Search
- Knuth-Morris-Pratt
- Boyer-Moore
- Rabin-Karp
Assignment
Boggle
Week - 5
Regular Expressions
- Regular Expressions
- Res and NFAs
- NFA Simulation
- NFA Construction
- RE Applications
Data Compression
- Introduction
- Run-Length Coding
- Huffman Compression
- LZW Compression
Assignment
Burrows-Wheeler
Week - 6
Reductions
- Introduction
- Designing Algorithms
- Establishing Lower Bounds
- Classifying Problems
Linear Programming
- Brewer's Problem
- Simplex Algorithm
- Simplex Implementations
- Linear Programming Reductions
Intractability
- Introduction
- Search Problems
- P vs NP
- Classifying Problems
- NP-Completeness
- Coping with Intractability
Interview Questions
1.1 Undirected Graphs
- Nonrecursive depth-first search. Implement depth-first search in an undirected graph without using recursion.
- Diameter and center of a tree. Given a connected graph with no cycles
- Diameter: design a linear-time algorithm to find the longest simple path in the graph.
- Center: design a linear-time algorithm to find a vertex such that its maximum distance from any other vertex is minimized.
- Euler cycle. An Euler cycle in a graph is a cycle (not necessarily simple) that uses every edge in the graph exactly one.
- Show that a connected graph has an Euler cycle if and only if every vertex has even degree.
- Design a linear-time algorithm to determine whether a graph has an Euler cycle, and if so, find one.
Assignments
WordNet: is a semantic lexicon for the English language that is used extensively by computational linguists and cognitive scientists
WordNet groups words into sets of synonyms called synsetsand describes semantic relationships between them.
One such relationship is theis-arelationship, which connects ahyponym(more specific synset) to ahypernym(more general synset).
For example,
- animal is a hypernym of both birdand fish;
- bird is a hypernym of eagle,pigeon, and seagull.
- Spoon is a hyponym of cutlery
References
http://coursera.cs.princeton.edu/algs4/assignments/wordnet.html
http://coursera.cs.princeton.edu/algs4/checklists/wordnet.html
https://github.com/CtheSky/Coursera-Algorithms/tree/master/Assignment6_WordNet