Deck 10: Object-Oriented Programming
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/60
Play
Full screen (f)
Deck 10: Object-Oriented Programming
1
____ is a programming model that focuses on an application's components and data and methods the components use.
A) Classical programming
B) Functional programming
C) Procedural programming
D) Object-oriented programming
A) Classical programming
B) Functional programming
C) Procedural programming
D) Object-oriented programming
D
2
Within any object-oriented program,you continuously make requests to an object's methods,often including arguments as part of those requests.
True
3
The concept of a class is useful because of its ____.
A) reusability
B) mapping to reality
C) abstract nature
D) portability
A) reusability
B) mapping to reality
C) abstract nature
D) portability
A
4
Instance variables are often called ____ to help distinguish them from other variables you might use.
A) rows
B) records
C) columns
D) fields
A) rows
B) records
C) columns
D) fields
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
5
The data components of a class that belong to every instantiated object are the class's ____.
A) numeric variables
B) string variables
C) instance variables
D) data variables
A) numeric variables
B) string variables
C) instance variables
D) data variables
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
6
The accessor method is another name for the set method.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
7
Class diagrams consists of a rectangle divided into three sections.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
8
A(n)____ is a program or class that instantiates objects of another prewritten class.
A) instantiation
B) method
C) class client
D) class definition
A) instantiation
B) method
C) class client
D) class definition
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
9
Methods in object-oriented programs use sequence,selection,and looping structures and make use of arrays.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
10
Object-oriented programmers usually specify that their data fields will have private access.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
11
Object-oriented programmers sometimes say an object is one ____ of a class.
A) enumeration
B) instantiation
C) member
D) reference
A) enumeration
B) instantiation
C) member
D) reference
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
12
No object is necessary with a static method.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
13
Methods in a class are static instance methods by default.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
14
Object-oriented programmers also use the term ____ when describing inheritance.
A) has-a
B) from-a
C) is-a
D) contains
A) has-a
B) from-a
C) is-a
D) contains
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
15
____ are the characteristics of an object.
A) Instances
B) Attributes
C) Behaviors
D) Methods
A) Instances
B) Attributes
C) Behaviors
D) Methods
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
16
Declaring a class does not create actual objects.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
17
All methods require a this reference.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
18
Objects both in the real world and in object-oriented programming contain ____ and methods.
A) behaviors
B) attributes
C) help
D) primitive data types
A) behaviors
B) attributes
C) help
D) primitive data types
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
19
In addition to their attributes,classes have methods associated with them,and every object instantiated from a given class possesses different methods.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
20
When you think in an object-oriented manner,every object is a member of a more general ____.
A) class
B) struct
C) method
D) collection
A) class
B) struct
C) method
D) collection
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
21
The term ____ implies that the type's data is private and can be accessed only through methods.
A) abstract type library
B) advanced data type
C) abstract definition type
D) abstract data type
A) abstract type library
B) advanced data type
C) abstract definition type
D) abstract data type
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
22
A(n)____ is a programmer-defined type,such as a class.
A) inheritance
B) numeric data type
C) primitive data type
D) abstract data type
A) inheritance
B) numeric data type
C) primitive data type
D) abstract data type
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
23
A(n)____________________ is one instance of a class.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
24
A program or class that instantiates objects of another prewritten class is a ____________________ .
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
25
A ____ method is also known as a help method.
A) work
B) private
C) public
D) set
A) work
B) private
C) public
D) set
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
26
Another important concept in object-oriented programming is ________,which is the process of acquiring the traits of one's predecessors.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
27
In most programming languages,you use the word ____ when you want to declare a static class member.
A) private
B) friend
C) public
D) static
A) private
B) friend
C) public
D) static
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
28
Methods that set values are called ____ methods.
A) modifier
B) mutator
C) creator
D) access
A) modifier
B) mutator
C) creator
D) access
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
29
In older object-oriented programming languages,simple numbers and characters are said to be ____ data types.
A) primitive
B) simple
C) complex
D) higher-order
A) primitive
B) simple
C) complex
D) higher-order
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
30
When methods have ____,other programs and methods may use the methods to get access to the private data.
A) private access
B) public access
C) complete access
D) all access
A) private access
B) public access
C) complete access
D) all access
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
31
A(n)____ consists of a rectangle divided into three sections.
A) class tree
B) dependency diagram
C) class diagram
D) entity-relationship diagram
A) class tree
B) dependency diagram
C) class diagram
D) entity-relationship diagram
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
32
The process of combining all of an object's attributes and methods into a single package is ____.
A) encapsulation
B) inheritance
C) information hiding
D) data hiding
A) encapsulation
B) inheritance
C) information hiding
D) data hiding
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
33
The purpose of a(n)____ is to return a value from the class to a client.
A) get method
B) set method
C) pull method
D) access method
A) get method
B) set method
C) pull method
D) access method
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
34
____ methods are methods that exist to be used with an object created from a class.
A) Nonstatic
B) Static
C) Hidden
D) Controlled
A) Nonstatic
B) Static
C) Hidden
D) Controlled
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
35
A(n)____ is the adjective that defines the type of access (public or private)outside classes will have to the attribute or method.
A) control specifier
B) control modifier
C) access specifier
D) access controller
A) control specifier
B) control modifier
C) access specifier
D) access controller
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
36
____________________ is the process of combining all of an object's attributes and methods into a single package.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
37
The purpose of ____ is to set or change the values of data fields defined within the class.
A) get methods
B) put methods
C) make methods
D) set methods
A) get methods
B) put methods
C) make methods
D) set methods
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
38
A ____ is a set of program statements that lists the characteristics of each object and the methods each object can use.
A) class interface
B) class definition
C) class reference
D) class model
A) class interface
B) class definition
C) class reference
D) class model
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
39
____ methods are those for which no object needs to exist.
A) Nonstatic
B) Public
C) Static
D) Private
A) Nonstatic
B) Public
C) Static
D) Private
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
40
When you think in an object-oriented manner,everything is a(n)____________________.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
41
List the two identifiers within a method that always mean exactly the same thing when you write an instance method in a class.
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.
-The set of all the values or contents of a class object's instance variables
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The set of all the values or contents of a class object's instance variables
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
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.
-List the three parts of a class definition.
-List the three parts of a class definition.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
44
Match each term with a statement below.
-List five important features of object-oriented languages.
-List five important features of object-oriented languages.
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.
-The data components of a class that belong to every instantiated object
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The data components of a class that belong to every instantiated object
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
46
Match each term with a statement below.
-The process of acquiring the traits of one's predecessors
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The process of acquiring the traits of one's predecessors
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
47
Match each term with a statement below.
-Describe what class diagrams list by convention.
-Describe what class diagrams list by convention.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
48
Discuss nonstatic methods.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
49
Match each term with a statement below.
-The characteristics that define an object as part of a class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The characteristics that define an object as part of a class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
50
Match each term with a statement below.
-The concept that other classes should not alter an object's attributes-only the methods of an object's own class should have that privilege
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The concept that other classes should not alter an object's attributes-only the methods of an object's own class should have that privilege
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
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.
-An instance of a class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-An instance of a class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
52
Match each term with a statement below.
-Explain encapsulation and information hiding.
-Explain encapsulation and information hiding.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
53
Match each term with a statement below.
-Describes a group or collection of objects with common attributes
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-Describes a group or collection of objects with common attributes
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
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.
-Explain what private access means in object-oriented programming.
-Explain what private access means in object-oriented programming.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
55
Discuss static methods.
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.
-Simple numbers and characters
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-Simple numbers and characters
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
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.
-The process of combining all of an object's attributes and methods into a single package
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-The process of combining all of an object's attributes and methods into a single package
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
58
Match each term with a statement below.
-Discuss why it is helpful to think of items as instances of a class.
-Discuss why it is helpful to think of items as instances of a class.
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.
-Discuss why the reusability of a class makes it useful.
-Discuss why the reusability of a class makes it useful.
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 or class that instantiates objects of another prewritten class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
-A program or class that instantiates objects of another prewritten class
A)instance variables
B)class client
C)inheritance
D)class
E)information hiding
F)state
G)primitive data types
H)attributes
I)encapsulation
J)object
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck