Add typing annotations to Python codes. (#411)

This commit is contained in:
Yudong Jin
2023-03-12 18:49:52 +08:00
committed by GitHub
parent 2029d2b939
commit 9151eaf533
50 changed files with 577 additions and 817 deletions

View File

@@ -81,7 +81,7 @@
```python title="hash_map.py"
""" 初始化哈希表 """
mapp = {}
mapp: Dict = {}
""" 添加操作 """
# 在哈希表中添加键值对 (key, value)
@@ -93,7 +93,7 @@
""" 查询操作 """
# 向哈希表输入键 key ,得到值 value
name = mapp[15937]
name: str = mapp[15937]
""" 删除操作 """
# 在哈希表中删除键值对 (key, value)