diff --git a/animation-simulation/数组篇/leetcode1两数之和.md b/animation-simulation/数组篇/leetcode1两数之和.md index 54c38ea..43be63b 100644 --- a/animation-simulation/数组篇/leetcode1两数之和.md +++ b/animation-simulation/数组篇/leetcode1两数之和.md @@ -100,7 +100,7 @@ public: for (int i = 0; i < nums.size(); ++i) { int t = target - nums[i]; if (m.count(t)) return { m[t], i }; - m[A[i]] = i; + m[nums[i]] = i; } return {}; }