Siemens interview question

Basic DS Algorithm question and regarding projects