File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -34,21 +34,12 @@ def sum_until(fn, n):
3434
3535
3636def without_parameters ():
37- """A function that does not accept parameters and does not return a value.
38-
39- This function is not used in this module, but it is defined to illustrate
40- that functions do not need to accept parameters or return values.
41- """
42- print ("This function does not accept parameters or return a value." )
37+ """A function that does not accept parameters and does not return a value."""
38+ pass
4339
4440
4541def sum (x : int , y : int ) -> int :
46- """A function that accepts parameters and has type hints.
47-
48- This function is not used in this module, but it is defined to illustrate
49- that functions can accept parameters and have type hints.
50- """
51-
42+ """A function that accepts parameters and has type hints."""
5243 return x + y
5344
5445
@@ -73,7 +64,7 @@ def main():
7364 # attribute! Remember this - everything in Python is an object
7465 assert "includes this docstring!" in sum_until .__doc__
7566
76- # Call the other two functions to ensure they work as expected
67+ # Call a few other functions to show that they are completely valid
7768 assert without_parameters () is None
7869 assert sum (1 , 2 ) == 3
7970
You can’t perform that action at this time.
0 commit comments