What happens when you attempt to compile and run the following code?
#include
#include
#include
using namespace std;
void print(int v) { cout< struct Sequence { int start; Sequence(int start):start(start){} int operator()() { return 10*(1+(start++ %3)); } }; int main() { vector generate_n(v1.begin(), 10, Sequence(1)); remove(v1.begin(), v1.end(), 10); for_each(v1.begin(), v1.end(), print);cout< return 0; } Program outputs:
Ming
3 months agoEmiko
3 months agoVirgie
3 months agoHelga
2 months agoMarion
2 months agoHelga
2 months agoRutha
2 months agoRenea
2 months agoTanja
2 months agoHyman
2 months agoHannah
3 months agoLauran
2 months agoKindra
3 months agoNicholle
3 months agoLeigha
3 months agoNikita
3 months agoLavonna
3 months agoAllene
3 months ago