Evolent interview question

Flatten array w/o built-in Methods