Skip to content

Commit cf852f1

Browse files
docs: Fix spelling and grammatical errors
1 parent 06cb5d6 commit cf852f1

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Classes/Inheritance.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
# Inheritance
44

5-
A class can inherit attributes from an other class called a super or parent class,
5+
A class can inherit attributes from another class called a super or parent class,
66
the former is called the child class
77

8-
Compare this to fruit.Apples and strawberries are both fruits and have
9-
the same basic prequisites for a typical fruit but each their own characteristics
8+
Compare this to fruit. Apples and strawberries are both fruits and have
9+
the same basic prerequisites for a typical fruit but each their own characteristics
1010
In this situation the parent class would be fruit and the child classes would be
1111
the apple and strawberry classes
1212

@@ -21,7 +21,7 @@ class class_name (super_class_name):
2121

2222
### Time for an example
2323

24-
So lets see an example based on the earlier one of fruits
24+
So let's see an example based on the earlier one of fruits
2525

2626
```python
2727
class fruit():
@@ -44,7 +44,7 @@ class Strawberry(fruit):
4444

4545
As before Strawberry and Apple inherit from fruit which means all of their
4646
objects will have the attributes of the class fruit but why should you believe me?
47-
Lets test it out by creating objects and seeing what happens
47+
Let's test it out by creating objects and seeing what happens
4848

4949
```python
5050
a = Apple()

0 commit comments

Comments
 (0)