The vector is similar to the std::vector implementation in the C++ STL. The key difference from other C vector implementation is that it should hold the actual contents of the data its stores, instead of storing pointers to the data. This allows the data to be accessed as the contiguous array it is and allows for better cache locality.
Requirements
[ ] Support data of any size
[ ] Support basic functions such as push, pop, and index
[ ] Allow for the entire internal array to be accessed
[ ] Write unit tests for the corresponding functions
Description
The vector is similar to the std::vector implementation in the C++ STL. The key difference from other C vector implementation is that it should hold the actual contents of the data its stores, instead of storing pointers to the data. This allows the data to be accessed as the contiguous array it is and allows for better cache locality.
Requirements