Skip to content

arahulc91/Two-Sum

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 

Repository files navigation

Two Sum (LeetCode #1)

Problem: Given an array of integers and a target sum, find two numbers in the array that add up to the target.

Key points:

  • Input: Integer array and target number
  • Output: Indices of two numbers that sum to target
  • Each input has exactly one solution
  • Same element cannot be used twice
  • Time complexity: O(n) using hash table
  • Space complexity: O(n)

View problem on LeetCode

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published