Explore topic-wise MCQs in C++ Programming.

This section includes 6 Mcqs, each offering curated multiple-choice questions to sharpen your C++ Programming knowledge and support exam preparation. Choose a topic below to get started.

1.

What is the output of this program?
#include 
using namespace std;
int main()
{
int num = 12;
if (num < 13)
{
T:
cout << num;
goto T;
}
break;
return 0;
}

A. 12
B. 13
C. Compilation Error
D. Runtime Error
E. None of these
Answer» D. Runtime Error
2.

What is the output of this program?
#include 
using namespace std;
int main ()
{
int i;
for (i = 10; i > 0; i--)
{
cout << i< if (i == 8)
break;
}
return 0;
}

A. 10 0
B. 0 10 8
C. 10 9 8
D. Compilation Error
E. None of these
Answer» D. Compilation Error
3.

The destination statement for the goto label is identified by what label?

A. *
B. $
C. :
D.
E. @None of these
Answer» D.
4.

How are many sequences of statements present in c++?

A. 3
B. 4
C. 5
D. 6
E. None of these
Answer» D. 6
5.

The switch statement is also called as?

A. selective structure
B. certain structure
C. choosing structure
D. All of above
E. None of these
Answer» B. certain structure
6.

The if..else statement can be replaced by which operator?

A. Multiplicative operator
B. Bitwise operator
C. Conditional operator
D. All of above
E. None of these
Answer» E. None of these