Đỗ Thu Hiền
New member
What will be the output of the following C++ code?
A. Test
B. string
C. Test string
D. Error
Code:
#include <iostream>
#include <string>
using namespace std;
int main ()
{
string str ("Test string");
for ( string :: iterator it = str.begin(); it != 5; ++it)
cout << *it;
return 0;
}
B. string
C. Test string
D. Error