-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Prabhsimran Singh edited this page Dec 25, 2018
·
14 revisions
These are C++ implementations of various algorithms and data structures optimized and modularized for peak performance and extensibility. This project includes support for C++11 std and can currently only be built on Linux.
You need to have any recent C++ compiler with C++11 support installed on your system along with a few pre-requisites:
The following commands will get you through the installation of the dependencies:
sudo apt-get install libboost-all-dev
sudo add-apt-repository ppa:george-edison55/cmake-3.x
sudo apt-get update
sudo apt-get install cmake
Once you're done with the above installation, you can build the project using CMAKE:
git clone https://github.com/pskrunner14/cpp-algs.git
cd cpp-algs/
./install.sh
-
Sorting
-
Searching
-
Miscellaneous
-
Basic
-
Linked List
-
Tree
-
Miscellaneous
// simply include a single header file
#include <cpp_algs.hpp>
// ...
// al namespace for algorithms
std::vector<int> v = {541, 12, 56, 62, 1234, 656547, 123, 1}
al::quickSort<int>(v);
// ...
// ds namespace for data structures
ds::Trie t;
t.insertWord("hello");
t.insertWord("world");
This project is distributed under the MIT License, see LICENSE for more information.