Past year June 2019 multiple choice question

Question 1: Select the symbol used for single line comment.

Question 2: Select the CORRECT answer based on the statement below.

Figure A2

Question 3: Identify the VALID variables.

Question 4: Identify the output from the program in Figure A4

Figure A4

Question 5: Select the CORRECT answer based on the statement below.

Figure A5

Question 6: Based on Figure A6, determine the CORRECT answer after execution.

Figure A6

Question 7: Based on Figure A7, determine the CORRECT output for logical expression below.

Figure A7

Question 8: Based on the options below, identify which is NOT the type of looping control structures?

Question 9: Figure A9 shows the condition statement in a selection control structure. Identify the CORRECT statement to write the condition statement in C++.

Figure A9

Question 10: Identify the number of repetitions that will occur for the following looping control structure in Figure A10.

Figure A10

Question 11: Based on the output as shown in Figure A11 below, assign the CORRECT C++ coding if X=50.

Figure A11
if (X >= 50)
cout<< "You pass the test \n";
else
cout<<"Sorry\n";
cout<<"Bye!\n";

Question 12: Based on the program as shown in Figure A12, choose the CORRECT output if X=A.

Figure A12

Question 13: Which of the following C++ statement is INCORRECT?

Question 14: Based on Figure A14, analyse the following code and determine the output if X=95.

Figure A14

Question 15: According to the flow chart as shown in Figure A15, determine the CORRECT C++ coding.

Figure A15

Question 16: Choose a declaration of C++ array with 6 integer value.

Question 17: Which of the following is a two-dimensional array with 5 colummns and 3 rows?

Question 18: Examine the C++ code shown in Figure A18 below and declare a structure variable "Äli" with initial value 18 for AGE and 3.82 for GPA.

Figure A18

Question 19: Analyse the C++ code as shown in Figure A19 below and determine the output.

Figure A19

Question 20: Choose the CORRECT C++ coding that access the eight (8th) element stored in Array "Nama".

Question 21: Determine the output for the code segment in Figure A21 below.

Figure A21

Question 22: Based on the Figure A22 below, select the suitable statement for X that produces an output 9.

Figure A22

Question 23: Based on the program in Figure A23 below, select the suitable statement for Z.

Figure A23

Question 24: Choose declaration prototype for Display function which does not return any value and receives two float type parameters.

Question 25: Based on Figure A25, choose the best answer for A.

Figure A25

Question 26: Identify the missing statement denoted by Y in the following program in Figure A26.

Figure A26

Question 27: Choose the CORRECT output based on the program in Figure A27 below.

Figure A27

Question 28: Determine the output from the program in Figure A28

Figure A28

Question 29: Based on Figure A29, analyse the code segment below and identify the output if the input is 20, 30, 25.

Figure A29

Question 30: Referring to Figure A30, identify the correct output.

Figure A30