solved JS Arrays task 6