Deloitte interview question

codility coding questions, there were 3 in all