Skip to content

Latest commit

 

History

History
22 lines (16 loc) · 635 Bytes

File metadata and controls

22 lines (16 loc) · 635 Bytes

Array Flatten exercise

Write some code, that will flatten an array of arbitrarily nested arrays of integers into a flat array of integers. e.g. [[1,2,[3]],4] -> [1,2,3,4].

When writing this code, you can use any language you're comfortable with. The code must be well tested and documented. Please include unit tests and any documentation you feel is necessary. In general, treat the quality of the code as if it was ready to ship to production.

Try to avoid using language defined methods like Ruby's Array#flatten.

Install all packages:

$ npm install

Run webpack

$ npm run build

Run tests

$ npm test