Hopper interview question

Some arrays manipulation