CPP Goto Statement MCQ

Cpp MCQ
  1. Home
  2. Tutorials
  3. Cpp
  4. Goto Statement
  5. Multiple Choice Question

(1) Label indentifier in goto statement always place _____ goto statement.

A) After
B) Before
C) Before main function
D) After main function

(2) Which of the following is valid goto statement syntax ?

A) goto (label)
B) goto {label}
C) goto label;
D) goto label:

(3) How many labels are used in single goto statement?

A) 1
B) 2
C) 3
D) 4

(4) In C++ how many identifiers are required to implement goto statement?

A) 1
B) 2
C) 3
D) 4

(5) Which of the following statement can also be used to implement iteration?

A) if
B) if else
C) goto
D) switch

(6) Which of the following operator is used after label in goto statement?

A) Colon :
B) Semi colon ;
C) Dot .
D) Comma ,

(7) Which of the following is used for unconditional control transfer?

A) if
B) switch
C) for
D) goto

.

Comments
Login to TRACK of Comments.