Samsung Electronics interview question

Data structures