C++ is my bae. I β€οΈ C++. A lot of people think C++ is ugly and horrible to work with so I decided why not create a series to help clear the path and navigate around the beautiful quirks of the language π.
Kicking things off with C++ Vectors and the Standard Template Library.
Within C++ you can include a library called vector in addition to the standard iostream C++ standard library.
#include is a preprocessor directive that tells the compiler to include whatever library follows, in our case that is the standard vector library. Since we will be working with the standard template library we will be using the standard namespace, makes our lives easier.
#include <iostream>
#include <vector>using namespace std;
Initializing and Populating
Time to init and pop some vectors.