COP1000 Final Exam Review
Questions With Correct Answers
Actual parameters occur in a function call. Formal parameters occur in the function definition. -
ANSTrue
Each array entry must be a different data type. - ANSFalse
In pseudocode , which verb is NOT used to assign a value to a variable or memory location? -
ANSDefine
If a program is required to prompt the user for his three test scores, accept the test scores as
integers, calculates and display to the screen the average of the three scores, how many processing
steps will you need? - ANS4
In the IF statement of a selection control structure a choice is made between two alternative paths,
depending on the result of a condition being true or false. - ANSTrue
If a program is required to do the following :
Prompt the user for his three test scores
Accept the test scores as integers
Calculate the average of the three scores
Display the results on the screen Using the information above, how many processing steps will you? -
ANS4
The selection control structure can be used to compare two variables and to follow one of two
alternate paths depending on the results of the comparison. - ANSTrue
The "WHILE" repetition structure can be directly translated into many high-level programming
languages. - ANSTrue
In C++ "assignment" and "test for equality" use different operator symbols. - ANSTrue
, The scope of a variable is the area of the program in which that variable has meaning. - ANSTrue
Procedural programming includes - ANStop-down Development
Each array entry must be a different data type. - ANSFalse
Use the following pseudocode
total = 0
start = 1
end = 5
DO count = start TO end
Prompt for a number
Get numbers count)
IF number is even THEN
total = total + numbers(count)
ENDIF
ENDDO
Display total
Display count
Assuming the input values,
1 3 5 7 10
what is output by "Display total"? - ANS10
Actual parameters occur in a function call. Formal parameters occur in the function definition. - ANST
Use the following pseudocode
/I Scope of count begins here
total = 0
start = 1
end = 5
Questions With Correct Answers
Actual parameters occur in a function call. Formal parameters occur in the function definition. -
ANSTrue
Each array entry must be a different data type. - ANSFalse
In pseudocode , which verb is NOT used to assign a value to a variable or memory location? -
ANSDefine
If a program is required to prompt the user for his three test scores, accept the test scores as
integers, calculates and display to the screen the average of the three scores, how many processing
steps will you need? - ANS4
In the IF statement of a selection control structure a choice is made between two alternative paths,
depending on the result of a condition being true or false. - ANSTrue
If a program is required to do the following :
Prompt the user for his three test scores
Accept the test scores as integers
Calculate the average of the three scores
Display the results on the screen Using the information above, how many processing steps will you? -
ANS4
The selection control structure can be used to compare two variables and to follow one of two
alternate paths depending on the results of the comparison. - ANSTrue
The "WHILE" repetition structure can be directly translated into many high-level programming
languages. - ANSTrue
In C++ "assignment" and "test for equality" use different operator symbols. - ANSTrue
, The scope of a variable is the area of the program in which that variable has meaning. - ANSTrue
Procedural programming includes - ANStop-down Development
Each array entry must be a different data type. - ANSFalse
Use the following pseudocode
total = 0
start = 1
end = 5
DO count = start TO end
Prompt for a number
Get numbers count)
IF number is even THEN
total = total + numbers(count)
ENDIF
ENDDO
Display total
Display count
Assuming the input values,
1 3 5 7 10
what is output by "Display total"? - ANS10
Actual parameters occur in a function call. Formal parameters occur in the function definition. - ANST
Use the following pseudocode
/I Scope of count begins here
total = 0
start = 1
end = 5