Use inheritance to create a new class that inherits attributes and methods from an existing class.
Source Code
class Animal:
def greet(self):
print("Hello, I am an animal.")
class Dog(Animal):
def greet(self):
super().greet()
print("And I am also a dog.")