What will be the output of the following C++ code? [code] #include <iostream> #include <string> using namespace std;

Duyên Trương

New member
What will be the output of the following C++ code?
Code:
    #include <iostream>
    #include <string>
    using namespace std;
    int main ()
    {
        string name ("Jobs");
        string family ("Steve");
        name += " Apple ";
        name += family;
        name += '\n';
        cout << name;
        return 0;
    }
A. Steve Jobs
B. Apple
C. Jobs Apple Steve
D. Apple Steve
 

Tìm kiếm

Back
Top