Nguyễn Thị Thuý
New member
What will be the output of the following C++ code?
A. apple
B. 12
C. 23
D. Steve jobs founded the
Code:
#include <iostream>
#include <string>
using namespace std;
int main ()
{
string str ("Steve jobs founded the apple");
string str2 ("apple");
unsigned found = str.find(str2);
if (found != string :: npos)
cout << found << '\n';
return 0;
}
B. 12
C. 23
D. Steve jobs founded the