Q. What is the output of this program?
Code:
#include
using namespace std;
void Output()
{
static int p = 1;
int k;
for(k=p; k<=3; k++)
{
p++;
cout << p;
}
}
int main()
{
Output();
Output();
Output();
return 0;
}
β
Correct Answer: (C)
234