This is a collection of algorithms which helps me learn about how to think logically and how to write code in C.
Below you can see a contents table with the algorithms studied by me.
I used Clion as a development tool, and compiled the code using the CMake build tool.
| Algorithm | File | Category | Time Complexity | Space Complexity |
|---|---|---|---|---|
| 0/1 Knapsack | dynamic_programming/knapsack.c |
Dynamic Programming | O(n × W) | O(n × W) O(W) - optimized version |
|
Each algorithm is a standalone .c file that can be compiled and run independently.
The algorithms are organized in folders, based on programming techniques.
Algorithms/
├── dynamic_programming/
│ └── knapsack.c
│
├── greddy_algorithms/
│ └──
│
├── encoding_algorithms/
│ └── huffman_encoding.c
│
└── README.md
Each file can be compiled individually with gcc:
gcc -o knapsack knapsack.c
./knapsackOr it can be built using CMake.
cmake commands that i don't yet knowAlgorithms planned or in progress will be tracked here as they're added — categories of interest include sorting, searching, graph algorithms, and more dynamic programming problems.