A structured guide to graph algorithms and dynamic programming techniques, with a focus on implementations in C
This repository provides a structured guide to graph algorithms and dynamic programming techniques, with a focus on implementations in C. Topics include:
- Bellman-Ford Algorithm: Single-source shortest path for graphs with negative weights.
- Dijkstra's Algorithm: Single-source shortest path using a priority queue.
- Prim's Algorithm: Minimum spanning tree using a greedy approach.
- Kruskal's Algorithm: Minimum spanning tree using union-find.
- Huffman Coding: Optimal encoding for data compression.
- Longest Common Subsequence (LCS): Finding the longest subsequence common to two strings.
- Matrix Chain Multiplication: Minimizing scalar multiplications for matrix multiplication.
- Activity Selection Problem: Selecting the maximum number of non-overlapping activities.
The PDF document contains theoretical insights, problem definitions, and well-documented C code implementations.
Algorithms-1.pdf: A comprehensive guide to algorithms with C implementations.- C Source Files:
bellman_ford.cdijkstra.cprims.ckruskal.chuffman.clcs.cmatrix_chain.cactivity_selection.c
- Clone the repository:
git clone https://github.com/arrhenius975/Algorithms_in_C.git
- Compile and run the programs:
for example:
gcc bellman_ford.c -o bellman_ford ./bellman_ford
Basic knowledge of C programming.
GCC compiler or equivalent.
GitHub: Zak @arrhenius975
Dedicated to: @r0s3-V3lv3t
Introduction to Algorithms by Cormen et al.
Algorithms by Robert Sedgewick and Kevin Wayne.
This project is licensed under the [MIT License](LICENSE).
See the LICENSE file for details.