js-zip
Implement zip function of python, used to transform a matrix,such as:
123 456 789
to:
147 258 369
Each row must be iteratable object,such as Array,String
Installation
npm i -S js-zip
Example
- Multi Arrays
const JsZip = ;const a = 123;const b = 456;const c = 789;const matrix = ;
output matrix is:
147 258 369
- Matrix
const JsZip = ;const arr = 123 456 789;const matrix = ;
output matrix is:
147 258 369
- String List
const JsZip = ;const arr = 'abc' 'def' 'xyz';const maxtrix = ;
output matrix is:
'a' 'd' 'x' 'b' 'e' 'y' 'c' 'f' 'z'
- Use