EAB interview question

Basic coding questions. No behavioral