what's the difference of back_inserter and inserter in c++# JobHunting - 待字闺中
s*n
1 楼
set_union (current_tree_indexes.begin(), current_tree_indexes.end(), tree_
indexes.begin(),tree_indexes.end(), inserter(tree_indexes, tree_indexes.end(
)));
is working.
But
set_union (current_tree_indexes.begin(), current_tree_indexes.end(), tree_
indexes.begin(),tree_indexes.end(), back_inserter(tree_indexes))
is not working...
indexes.begin(),tree_indexes.end(), inserter(tree_indexes, tree_indexes.end(
)));
is working.
But
set_union (current_tree_indexes.begin(), current_tree_indexes.end(), tree_
indexes.begin(),tree_indexes.end(), back_inserter(tree_indexes))
is not working...