-
What is the output of this program?
#include <iostream>
#include <string>
using namespace std;
int main ()
{
string Str;
char StrArray[30]= "Hello Interview Mania";
Str = StrArray;
cout << Str << '\n';
return 0;
}
-
- Hello
- Interview
- Mania
- Hello Interview Mania
- Compilation Error
Correct Option: D
In this program, We converted the char values into the string.