Vectors are data structures similar to array but with features such as dynamic memory, resizable container, insertion and deletion of elements. Vector elements are places in contiguous storage so that they can be accessed and traversed using iterators. A 2D vector is vector of vectors. It is an matrix implemented with the help of vectors.
In this article, we will explore different ways to sort a 2 dimensional (2D) vector in C++ which includes sorting by row, column, a specific row or a specific...
Published on May 20, 2020 16:01