Search
⌘K
Leetcode 1. Two Sum
Given an array of integers and a target, return the indices of two distinct elements whose values sum to the target (exactly one valid solution exists). The core challenge is efficiently finding complementary values (aiming for better than O(n^2) brute force).
Asked at:
B
Brex
ServiceNow
Meta
Amazon
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Mid February, 2026
B
Brex
Senior
Early October, 2025
Meta
Mid-level
Early March, 2025
ServiceNow
Staff
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.