Medium-EasyApplyHash TablesMultiple Choice

In Two Sum (LC 1), what is stored as key and value in the hash map?

Apply Tests ability to use knowledge in practical scenarios.

Answer Options

AKey=index, Value=number
BKey=number, Value=index
CKey=number, Value=complement
DKey=complement, Value=number

Want to see the correct answer?

Get the answer with a detailed explanation, plus practice 32+ more Hash Tables questions with adaptive quizzes and timed interviews.

See the Answer on Guru Sishya →

This question is from the Hash Tables topic (Data Structures).

More Hash Tables Questions