A subclass is usually:
more specialized than its superclass
An object is characterized by the following three:
name, properties, activites
An alternative name for a data structure calls a stack is:
LIFO
A variable that exists as a separate being in separate objects is called:
an instance variable
A function able to check if an object is equipped with a given property is named:
hasattr()
Is there a way to check if a class is a subclass of another class?
yes, there is a function able to do that
The function named super() may be used to:
access a super class’s attributes and/or methods
A user defined exception
may be derived from the exception class
Which two are true?
A. the args property is a tuple designed to gather all arguments passed to the class constructor.
B. The finally branch of the try statement is always executed.
What is the output of the following?
import math
try:
print(math.pow(2))
except TypeError:
print(“A”)
else:
print(“B”)
A