From ad2cf8d49e58b40a50f773617b312f83468a49a6 Mon Sep 17 00:00:00 2001 From: Cyphrr_07 <93258479+AsifQamar@users.noreply.github.com> Date: Fri, 22 Aug 2025 00:35:06 +0530 Subject: [PATCH] Update 1.Two_Sum (fixed time and space complexcity) TC was N^2 ---> it will be N as you are using map SC will be N too --- cpp/problems/leetcode/easy/1.Two_Sum | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cpp/problems/leetcode/easy/1.Two_Sum b/cpp/problems/leetcode/easy/1.Two_Sum index 2313ee2..663d49a 100644 --- a/cpp/problems/leetcode/easy/1.Two_Sum +++ b/cpp/problems/leetcode/easy/1.Two_Sum @@ -1,8 +1,8 @@ /* URL:https://leetcode.com/problems/two-sum/description/ -Time Complexity: O(N^2) -Space Complexity: O(1) +Time Complexity: O(N) +Space Complexity: O(N) Author:Fatima Aslam (~^ - ^~)