Question: What is output? #include using namespace std; class Greet { public: string g 1 ; string g 2 ; string g 3 ; string g
What is output?
#include
using namespace std;
class Greet
public:
string g;
string g;
string g;
string g;
void Print const;
Greet
gHi;
g "Good morning! ;
g "Good night! ;
;
void Greet::Print const
cout g g g;
int main
Greet user;
userPrint;
userg "Hello!";
Group of answer choices
Hi Hello! Good morning! Good night!
Hi Good morning! Good night!
Hi Good morning!
Hi Hello! Good morning!
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
