Given a list of numbers, write an optimized program to find a pair of numbers that add up to a specific target sum. Explain how to achieve O(N) time complexity.
Problem
Given a list of numbers, write an optimized program to find a pair of numbers that add up to a specific target sum. Explain how to achieve O(N) time complexity.
Your answer
Try one AI text evaluation on us
Get structured feedback, scored against a 4-axis rubric. Premium unlocks unlimited.