solulubeta
Sign in
NeetCode 150 / Arrays & Hashing
01.03 · Problem

Two Sum

Easy Hash map of complements 1 video LC 1 Pro

This problem is part of solulu Pro

Given an array of integers nums and an integer target, return the indices of the two different elements that add up to target. Exactly one such pair exists. You may return the two indices in any order.

Lifetime ₹2,000 ₹1,000 · Beta offer
Mark this problem as solved when you are finished.

Item 3 of 9 · updated 2026-10-12