1. (TCO 5) Source code documentation includes _____. (Points : 2)
data dictionary
program comments
print chart
syntax diagrams
Question 2.2. (TCO 5) What name is best suited to a module that calculates overtime pay? (Points : 2)
calcO( )
calculate overtime( )
cO( )
calculateOvertime( )
Question 3.3. (TCO 5) If a subroutine or function is useful and well-written, you may want to use it more than once within a program or in other programs. This is known as _____. (Points : 2)
reliability
abstraction
scalability
reusability
Question 4.4. (TCO 5) Programs are easier to understand if you break their logic down into a few major code blocks called _____. (Points : 2)
segments
directories
objects
modules
Question 5.5. (TCO 5) What variable scope is preferable in modules to avoid overwriting existing data? (Points : 2)
Implicit
Global
Local and global
Local
Question 6.6. (TCO 5) What statement is not an advantage of using modularization? (Points : 2)
Easier to debug programs
Programs to be worked on by separate programmers
Code is reusable.
Programs are longer and more complex.
Question 7.7. (TCO 5) In what way do named constants differ from variables? (Points : 2)
There is no difference.
The value of a constant does not change.
Constants do not have identifier names.
Constants are not used in modern programming.
Question 8.8. (TCO 5) Which of the following would most likely be a named constant? (Points : 2)
x
taxRate
isFinished
TAX_RATE
Question 9.9. (TCO 5) What is a feature of good program design? (Points : 2)
Short identifiers are preferred over descriptive identifiers.
Literal constants are preferred over named constants.
There should never be empty lines between blocks of related statements.
Subroutines and functions should be used to modularize major programming tasks.
Question 10.10. (TCO 5) Which VBScript statements below represent an acceptable definition for the subroutine displayResults( )? (Points : 2)
Sub displayResults( )
WScript.StdOut.WriteLine(“RESULTS“)
End Sub
Function displayResults( )
WScript.StdOut.WriteLine(“RESULTS“)
End Function
Subroutine displayResults( )
WScript.StdOut.WriteLine(“RESULTS“)
End Subroutine
Call displayResults( )
WScript.StdOut.WriteLine(“RESULTS“)
End Call
Комментариев нет:
Отправить комментарий