Deck 9: Advanced Modularization Techniques

Full screen (f)
exit full mode
Question
A method's declared return type must match the type of value used in the return statement.
Use Space or
up arrow
down arrow
to flip the card.
Question
Methods with identical names that have identical parameter lists but different return types are ambiguous.
Question
You can invoke or call a method from another program or method.
Question
When a copy of a variable is sent to a method,it is passed by ____.

A) reference
B) inference
C) insinuation
D) value
Question
The input value that makes the recursion stop is called the base case or ending case.
Question
A method could be called using any numeric value as an argument,whether it is a variable,a named constant,or a literal constant.
Question
All modern programming languages contain many methods that are predefined.
Question
In implementation hiding,the calling method needs to understand only the interface to the method that is called and it need not know how the method works internally.
Question
A method's name and parameter list constitute the method's ____.

A) header
B) interface
C) contract
D) signature
Question
Variables and constants are ____ within,or local to,only the method in which they are declared.

A) in scope
B) out of bounds
C) out of scope
D) limited
Question
Each time a method executes,any parameter variables listed in the method header are ____.

A) examined
B) redeclared
C) referenced
D) copied
Question
A called method accepts the value of an argument passed to it as its ____.

A) parameter
B) reference
C) baseline
D) argument
Question
When methods must share data,you can pass the data into and return the data out of methods.
Question
A method's return type is part of its signature.
Question
The variables in the method declaration that accept the values from the actual parameters are ____ parameters.

A) defined
B) proper
C) formal
D) actual
Question
When a data item is known to all of a program's modules,it is a ____data item.

A) scope
B) defined
C) local
D) global
Question
A calling method sends a(n)____ to a called method.

A) parameter
B) interface
C) object
D) argument
Question
The last statement in a method is a(n)____.

A) begin statement
B) return statement
C) exit statement
D) end statement
Question
Programs that use recursion are error-prone but easy to debug.
Question
You can think of the ____ in a method declaration as a funnel into the method.

A) braces
B) brackets
C) parentheses
D) commas
Question
A method that calls itself is a ____.

A) recursive method
B) repeated method
C) self-referencing method
D) simple method
Question
Using recursion successfully requires a thorough understanding of ____________________.
Question
Programmers use the term ____ to describe any extra time and resources required by an operation.

A) black box
B) overhead
C) overload
D) cohesion
Question
Programmers refer to hidden implementation details as existing in a(n)____________________.
Question
A(n)____________________ chart is a tool that identifies and categorizes each item needed within the method as pertaining to input,processing,or output.
Question
The method name and parameter list constitute the ____.

A) signature
B) input list
C) title
D) variable list
Question
____ is a measure of the strength of the connection between two program methods.

A) Coupling
B) Cohesion
C) Bonding
D) Binding
Question
When you ____ a method,you write multiple methods with a shared name but different parameter lists.

A) stack
B) overload
C) overhead
D) void
Question
A method can return nothing,in which case the method is a ____ method.

A) null
B) void
C) nul
D) empty
Question
____ provide an overview of input to the method,the processing steps that must occur,and the result.

A) Stacks
B) Hierarchy charts
C) IPO charts
D) Flowcharts
Question
Arrays,unlike simple built-in types,are passed by ____.

A) deference
B) value
C) reference
D) configuration
Question
When a data item is known to all of a program's modules,it is a(n)____________________ data item.
Question
____ refers to how the internal statements of a method serve to accomplish the method's purpose.

A) Coupling
B) Cohesion
C) Bonding
D) Binding
Question
When the method ends at the ____________________ statement,the locally declared parameter variable ceases to exist.
Question
____ occurs when a method is defined in terms of itself.

A) Referential integrity
B) Repeatability
C) Dependence
D) Recursion
Question
____ occurs when methods do not depend on others.

A) Tight coupling
B) Loose coupling
C) Data coupling
D) Abstract coupling
Question
____ is the ability of a method to act appropriately depending on the context.

A) Cohesion
B) Chameleon
C) Integrity
D) Polymorphism
Question
____ occurs when methods excessively depend on each other and makes programs more prone to errors.

A) Late coupling
B) Loose coupling
C) Tight coupling
D) Weak coupling
Question
Using implementation hiding means that the ____ is the only part of a method with which the method's client interacts.

A) argument list
B) interface to the method
C) parameter list
D) internal detail
Question
Every time you call a method,the address to which the program should return at the completion of the method is stored in a memory location called the ____.

A) heap
B) queue
C) stack
D) dump
Question
Match each term with a statement below.


-When the method receives the actual memory address of the array and has access to the actual values in the array elements

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Match each term with a statement below.


-?Multiple methods with a shared name but different parameter lists

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Match each term with a statement below.


-The ability of a method to act appropriately according to the context

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Explain what happens when you call a method and the method ends.
Question
Match each term with a statement below.


-A copy of a variable's value is sent to the method and stored in a new memory location accessible to the method

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Describe recursion.
Question
List the four things you need to know when you call a method from a program or other method.
Question
Describe how you create and use a method with multiple parameters.
Question
Discuss loose coupling.
Question
List the items that must be included within the method declaration's parentheses.
Question
Match each term with a statement below.


-Occurs when a copy of data that must be shared is passed from one method to another

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Discuss tight coupling.
Question
Describe what a method's return statement can return.
Question
Match each term with a statement below.


-When all the operations in a method contribute to the performance of a single task

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Discuss the cumulative summing relationship.
Question
Match each term with a statement below.


-The arguments sent to a method in a method call

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Match each term with a statement below.


-Contains identifying information about the method

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
List the three things that you need to know to design effective methods.
Question
Match each term with a statement below.


-Occurs when methods have access to the same globally defined variables

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Question
Match each term with a statement below.


-A program module that contains a series of statements that carry out a task

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/60
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 9: Advanced Modularization Techniques
1
A method's declared return type must match the type of value used in the return statement.
True
2
Methods with identical names that have identical parameter lists but different return types are ambiguous.
True
3
You can invoke or call a method from another program or method.
True
4
When a copy of a variable is sent to a method,it is passed by ____.

A) reference
B) inference
C) insinuation
D) value
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
5
The input value that makes the recursion stop is called the base case or ending case.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
6
A method could be called using any numeric value as an argument,whether it is a variable,a named constant,or a literal constant.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
7
All modern programming languages contain many methods that are predefined.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
8
In implementation hiding,the calling method needs to understand only the interface to the method that is called and it need not know how the method works internally.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
9
A method's name and parameter list constitute the method's ____.

A) header
B) interface
C) contract
D) signature
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
10
Variables and constants are ____ within,or local to,only the method in which they are declared.

A) in scope
B) out of bounds
C) out of scope
D) limited
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
11
Each time a method executes,any parameter variables listed in the method header are ____.

A) examined
B) redeclared
C) referenced
D) copied
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
12
A called method accepts the value of an argument passed to it as its ____.

A) parameter
B) reference
C) baseline
D) argument
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
13
When methods must share data,you can pass the data into and return the data out of methods.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
14
A method's return type is part of its signature.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
15
The variables in the method declaration that accept the values from the actual parameters are ____ parameters.

A) defined
B) proper
C) formal
D) actual
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
16
When a data item is known to all of a program's modules,it is a ____data item.

A) scope
B) defined
C) local
D) global
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
17
A calling method sends a(n)____ to a called method.

A) parameter
B) interface
C) object
D) argument
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
18
The last statement in a method is a(n)____.

A) begin statement
B) return statement
C) exit statement
D) end statement
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
19
Programs that use recursion are error-prone but easy to debug.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
20
You can think of the ____ in a method declaration as a funnel into the method.

A) braces
B) brackets
C) parentheses
D) commas
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
21
A method that calls itself is a ____.

A) recursive method
B) repeated method
C) self-referencing method
D) simple method
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
22
Using recursion successfully requires a thorough understanding of ____________________.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
23
Programmers use the term ____ to describe any extra time and resources required by an operation.

A) black box
B) overhead
C) overload
D) cohesion
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
24
Programmers refer to hidden implementation details as existing in a(n)____________________.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
25
A(n)____________________ chart is a tool that identifies and categorizes each item needed within the method as pertaining to input,processing,or output.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
26
The method name and parameter list constitute the ____.

A) signature
B) input list
C) title
D) variable list
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
27
____ is a measure of the strength of the connection between two program methods.

A) Coupling
B) Cohesion
C) Bonding
D) Binding
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
28
When you ____ a method,you write multiple methods with a shared name but different parameter lists.

A) stack
B) overload
C) overhead
D) void
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
29
A method can return nothing,in which case the method is a ____ method.

A) null
B) void
C) nul
D) empty
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
30
____ provide an overview of input to the method,the processing steps that must occur,and the result.

A) Stacks
B) Hierarchy charts
C) IPO charts
D) Flowcharts
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
31
Arrays,unlike simple built-in types,are passed by ____.

A) deference
B) value
C) reference
D) configuration
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
32
When a data item is known to all of a program's modules,it is a(n)____________________ data item.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
33
____ refers to how the internal statements of a method serve to accomplish the method's purpose.

A) Coupling
B) Cohesion
C) Bonding
D) Binding
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
34
When the method ends at the ____________________ statement,the locally declared parameter variable ceases to exist.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
35
____ occurs when a method is defined in terms of itself.

A) Referential integrity
B) Repeatability
C) Dependence
D) Recursion
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
36
____ occurs when methods do not depend on others.

A) Tight coupling
B) Loose coupling
C) Data coupling
D) Abstract coupling
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
37
____ is the ability of a method to act appropriately depending on the context.

A) Cohesion
B) Chameleon
C) Integrity
D) Polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
38
____ occurs when methods excessively depend on each other and makes programs more prone to errors.

A) Late coupling
B) Loose coupling
C) Tight coupling
D) Weak coupling
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
39
Using implementation hiding means that the ____ is the only part of a method with which the method's client interacts.

A) argument list
B) interface to the method
C) parameter list
D) internal detail
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
40
Every time you call a method,the address to which the program should return at the completion of the method is stored in a memory location called the ____.

A) heap
B) queue
C) stack
D) dump
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
41
Match each term with a statement below.


-When the method receives the actual memory address of the array and has access to the actual values in the array elements

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
42
Match each term with a statement below.


-?Multiple methods with a shared name but different parameter lists

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
43
Match each term with a statement below.


-The ability of a method to act appropriately according to the context

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
44
Explain what happens when you call a method and the method ends.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
45
Match each term with a statement below.


-A copy of a variable's value is sent to the method and stored in a new memory location accessible to the method

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
46
Describe recursion.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
47
List the four things you need to know when you call a method from a program or other method.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
48
Describe how you create and use a method with multiple parameters.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
49
Discuss loose coupling.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
50
List the items that must be included within the method declaration's parentheses.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
51
Match each term with a statement below.


-Occurs when a copy of data that must be shared is passed from one method to another

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
52
Discuss tight coupling.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
53
Describe what a method's return statement can return.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
54
Match each term with a statement below.


-When all the operations in a method contribute to the performance of a single task

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
55
Discuss the cumulative summing relationship.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
56
Match each term with a statement below.


-The arguments sent to a method in a method call

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
57
Match each term with a statement below.


-Contains identifying information about the method

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
58
List the three things that you need to know to design effective methods.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
59
Match each term with a statement below.


-Occurs when methods have access to the same globally defined variables

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
60
Match each term with a statement below.


-A program module that contains a series of statements that carry out a task

A)functional cohesion
B)passed by value
C)actual parameters
D)loose coupling
E)method
F)overload a method?
G)passed by reference
H)method header
I)tight coupling
J)polymorphism
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 60 flashcards in this deck.