Answer: C
Explanation: had an assignment and this was the answer
Answer:
B.
Explanation:
Go to the Borders and Shading option, click the Shading tab, and click the color under the Fill option.
Python Code:
class Dog:
""" Dog class definition """
# data attribute species as part of the class Dog
species = "Canis familiaris"
def __init__(self, _name, _breed):
""" Constructor """
# Assigning values
self.name = _name
self.breed = _breed
self.tricks = []
def teach(self, trick):
""" add a passed string parameter to tricks """
# Adding to list
self.tricks.append(trick)
# Printing message
print(self.name + " knows " + trick)
def knows(self, chkStr):
""" check whether a passed string parameter is in the dog’s list of tricks """
# Checking in tricks list
if chkStr in self.tricks:
# Printing message
print("Yes, " + self.name + " knows " + chkStr)
else:
# Printing message
print("No, " + self.name + " doesn't know " + chkStr)