Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitafe5dab

Browse files
committed
Fix reported issue "First file contains wrong comment#2"
Missed to remove the print() function in get_value()
1 parent2c31868 commitafe5dab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎01-encapsulation-1.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def set_val(self, val):
1717
self.value=val
1818

1919
defget_val(self):
20-
print(self.value)
20+
#print(self.value)
2121
returnself.value
2222

2323
a=MyClass()
@@ -38,4 +38,4 @@ def get_val(self):
3838
# a) Either replace `return self.value` with `print(self.value)`
3939
# or add a print statement **above** `return` as `print(self.value)`.
4040

41-
# b) Remove `return(self.value)` and replace it with `print(self.value)`
41+
# b) Remove `return(self.value)` and replace it with `print(self.value)`

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp