#8 Refactor array