Fix a typo.

This commit is contained in:
krahets
2023-05-26 04:31:14 +08:00
parent 11c835d79c
commit afb08a26e0
3 changed files with 13 additions and 12 deletions

View File

@@ -79,7 +79,7 @@
考虑借助一个哈希表,键值对分别为数组元素和元素索引。循环遍历数组,每轮执行:
1. 判断数字 `target - nums[i]` 是否在哈希表中,若是则直接返回这两个元素的索引;
2. 将键值对 `num[i]` 和索引 `i` 添加进哈希表;
2. 将键值对 `nums[i]` 和索引 `i` 添加进哈希表;
=== "<1>"
![辅助哈希表求解两数之和](replace_linear_by_hashing.assets/two_sum_hashtable_step1.png)