Top "Vector" questions

A vector is a single-dimensional array: it contains components that can be accessed using an integral index.

Iterating C++ vector from the end to the beginning

Is it possible to iterate a vector from the end to the begin? for (vector<my_class>::iterator …

c++ vector iterator
sorting a vector of structs

I have a vector<data> info where data is defined as: struct data{ string word; int number; }; I …

c++ sorting vector
Using std::max_element on a vector<double>

I'm trying to use std::min_element and std::max_element to return the min and max elements in a …

c++ vector max min
Rotation of 3D vector?

I have two vectors as Python lists and an angle. E.g.: v = [3,5,0] axis = [4,4,1] theta = 1.2 #radian What is the best/…

python vector rotation
"Cannot allocate an object of abstract type" error

Error is here: vector<Graduate *> graduates; graduates.push_back(new AliceUniversity(identifier,id,salary,average)); Grandparent class: Graduate::…

c++ vector data-structures pure-virtual
How do I make a matrix from a list of vectors in R?

Goal: from a list of vectors of equal length, create a matrix where each vector becomes a row. Example: > …

r matrix vector
Using atan2 to find angle between two vectors

I understand that: atan2(vector.y, vector.x) = the angle between the vector and the X axis. But I wanted …

math vector geometry
How can I get the size of an std::vector as an int?

I tried: #include <vector> int main () { std::vector<int> v; int size = v.size; } but got …

c++ vector size constants unsigned-integer
How to copy std::string into std::vector<char>?

Possible Duplicate: Converting std::string to std::vector<char> I tried: std::string str = "hello"; std::vector<…

c++ string vector copy
Can't include C++ headers like vector in Android NDK

When I try to include any C++ class like vector in my Android NDK project (using NDK r5b, the …

android stl vector android-ndk