++


set_union()


template< class InputIterator1, class InputIterator2,

class OutputIterator >

OutputIterator

set_union(InputIterator1 first1, InputIterator1 last1,

InputIterator2 first2, InputIterator2 last2,

OutputIterator result );

template< class InputIterator1, class InputIterator2,

class OutputIterator, class Compare >

OutputIterator

set_union(InputIterator1 first1, InputIterator1 last1,

InputIterator2 first2, InputIterator2 last2,

OutputIterator result, Compare comp );

set_union() , [first1,last1),   [first2,last2), . , {0,1,2,3} {0,2,4,6} {0,1,2,3,4,6}. , . result. , , ; comp.

#include <algorithm>

#include <set>

#include <string>

#include <iostream.h>

/* :

#1:

-

#2:

set_union():

-

set_intersection():

 

set_difference():

-

 

_symmetric_difference():

-

*/

int main()

{

string str1[] = { "", "", "", "-" };

string str2[] = { "", "", "" };

ostream_iterator< string > ofile( cout, " " );




- -  - -  - -