Skip to content

Commit 01c281f

Browse files
committed
Update instructions and fix method names
1 parent 2e657f9 commit 01c281f

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# Create a class called Student with instance attributes: Name and Age.
2-
# The user can input the Name and Age. Add 2 methods to the class:
3-
# A raiseHand method which prints out the student name followed
4-
# by is now raising their hand.” A growOlder method that makes the
5-
# student older by 1 year.
1+
# Create a class called Student with instance attributes: name and age.
2+
# The user can input the name and age. Add 2 methods to the class:
3+
# 1. A raise_hand method which prints out the student's name followed
4+
# by "is now raising their hand."
5+
# 2. A grow_older method that makes the student older by 1 year.
Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
# Create a class called Student with instance attributes: Name and Age.
2-
# The user can input the Name and Age. Add 2 methods to the class:
3-
# A raiseHand method which prints out the student name followed
4-
# by is now raising their hand.” A growOlder method that makes the
5-
# student older by 1 year.
1+
# Create a class called Student with instance attributes: name and age.
2+
# The user can input the name and age. Add 2 methods to the class:
3+
# 1. A raise_hand method which prints out the student's name followed
4+
# by "is now raising their hand."
5+
# 2. A grow_older method that makes the student older by 1 year.
66

77

88
class Student:
99
def __init__(self, name, age):
1010
self.name = name
1111
self.age = age
1212

13-
def raiseHand(self):
13+
def raise_hand(self):
1414
print(self.name + " is now raising their hand.")
1515

16-
def growOlder(self):
16+
def grow_older(self):
1717
self.age += 1

0 commit comments

Comments
 (0)