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

Commitaa7fa67

Browse files
authored
Merge pull requestwilfredinni#58 from samithamphk/master
Update README.md
2 parents719c1f1 +49b0c30 commitaa7fa67

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

‎README.md‎

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -966,18 +966,19 @@ not, and even if an exception is not caught.
966966
>>>print('Error: Invalid argument:{}'.format(e))
967967
>>>finally:
968968
>>>print("-- division finished --")
969-
>>>print(spam(12))
970-
>>>print(spam(0))
969+
>>>print(spam(2))
970+
-- division finished--
971971
21.0
972+
>>>print(spam(12))
972973
-- division finished--
973974
3.5
974-
-- division finished--
975-
Error: Invalidargument: division by zero
975+
>>>print(spam(0))
976+
Error: InvalidArgument division by zero
976977
-- division finished--
977978
None
979+
>>>print(spam(1))
978980
-- division finished--
979981
42.0
980-
-- division finished--
981982
```
982983

983984
[*Return to the Top*](#python-cheatsheet)
@@ -1485,6 +1486,8 @@ True
14851486

14861487
###The get() Method
14871488

1489+
Get has two parameters: key and default value if the key did not exist
1490+
14881491
```python
14891492
>>> picnic_items= {'apples':5,'cups':2}
14901493

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp