What happens when you attempt to compile and run the following code?
#include
#include
#include
using namespace std;
template
ostream & out;
Out(ostream & o): out(o){}
void operator() (const T & val ) { out< int main() { int t1[]={3,2,4,1,5}; int t2[]={5,6,8,2,1}; vector sort(t1, t1+5); sort(t2, t2+5); set_union(t1,t1+5,t2,t2+5,v1.begin()); for_each(v1.begin(), v1.end(), Out return 0; } Program outputs:
Berry
4 months agoRyann
4 months agoElvera
4 months agoLavonna
2 months agoElmira
3 months agoJaleesa
3 months agoZack
3 months agoKimberely
4 months agoEleonora
3 months agoLeota
3 months agoLaura
3 months agoLacey
4 months agoCandida
3 months agoHershel
3 months agoDorethea
3 months agoArthur
5 months agoRanee
5 months agoKiera
5 months agoJillian
5 months agoLynna
5 months agoJillian
5 months ago