push back multiple types of data in a vector in c++

Viewed 1497

Let's say I have a vector full of points like this:

vector<Point3f> cluster_points

Now I am getting distance between 2 points for each point in the vector. I want to store all these data in a container like below:

{distance, (both point's index number from *cluster_points*)}  

e.g.

{70.54,  (0,1)};
{98.485, (1,2)};
{87.565, (2,3)};
{107.54, (3,4)};

How can I do this in C++11?

3 Answers
Related