is there a way to swap the first and second elements for all tuples in a vector? Let's say I have something like this:
#include<vector>
#include<tuple>
int main()
{
std::vector<std::tuple<int,int>> my_vector;
my_vector.push_back(std::make_tuple(1,2));
my_vector.push_back(std::make_tuple(3,4));
}
The first elements of the tuple are now 1 and 3 with the second elements being 2 and 4. Is there an easy to make 2 and 4 the first elements?