Skip to content

Commit 447f254

Browse files
committed
修复代码
1 parent fb6e7d2 commit 447f254

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

pprint.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,16 @@ print 将打印的结果显示在一行,可读性差
1212
pprint 对打印结果进行了格式化处理,可读性提高了很多
1313

1414
```python
15-
import pprint
15+
>>> import pprint
16+
>>> pprint.pprint(locals())
1617

17-
pprint.pprint(locals())
1818
{'__annotations__': {},
1919
'__builtins__': <module 'builtins' (built-in)>,
2020
'__doc__': None,
2121
'__loader__': <class '_frozen_importlib.BuiltinImporter'>,
2222
'__name__': '__main__',
2323
'__package__': None,
2424
'__spec__': None,
25-
'a': {'a': 1},
26-
'b': {'b': 2},
27-
'c': {'a': 1, 'b': 2},
28-
}
25+
'pprint': <module 'pprint' from 'C:\\Users\\lzjun\\AppData\\Local\\Programs\\Python\\Python37-32\\lib\\pprint.py'>}
26+
>>>
2927
```

0 commit comments

Comments
 (0)