生成随机序列
用法:
$ npm install --save randomatic
var randomize = require('randomatic');
randomize(pattern, length, options);
eg:
randomize('*', 10);
//=> 'x2_^-5_T[$'
randomize('Aa0!', 10);
//=> 'LV3u~BSGhw'
生成长度为100的数组,每个元素为0:
const record = Array.apply(null, Array(100)).map(() => {
return 0;
});