Skip to content

Commit f2d2304

Browse files
authored
Update controlflow.rst
1 parent 6685c45 commit f2d2304

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Doc/tutorial/controlflow.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -880,7 +880,7 @@ the positional-or-keyword parameter ``name`` and the var-keyword parameter
880880
def foo(name, **kwds):
881881
return 'name' in kwds
882882

883-
Calling `foo()` gets error because `name` parameter can receive both the 1st and
883+
Calling ``foo()`` gets error because `name` parameter can receive both the 1st and
884884
2nd argument by position and keyword respectively::
885885

886886
>>> foo(1, name=2)
@@ -889,9 +889,9 @@ Calling `foo()` gets error because `name` parameter can receive both the 1st and
889889
TypeError: foo() got multiple values for parameter 'name'
890890
>>>
891891

892-
But using ``/`` (positional-only parameters) and calling `foo()` works because
892+
But using ``/`` (positional-only parameters) and calling ``foo()`` works because
893893
``name`` parameter can only receive the 1st argument by position while
894-
`**kwds` receives the 2nd argument by keyword::
894+
``**kwds`` receives the 2nd argument by keyword::
895895

896896
>>> def foo(name, /, **kwds):
897897
... return 'name' in kwds

0 commit comments

Comments
 (0)