function random_string(size) {
const characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';
const len = characters.length;
let rnd = '';
for (let i = 0; i < size; i++) {
rnd += characters.charAt(Math.floor(Math.random() * len));
}
return rnd;
}
for (let i = 0; i < 10; i++) {
let s = (random_string(5));
console.log(s);
}
/*
run:
"Ptuax"
"KicvZ"
"ErJdR"
"IIAYH"
"lwwzk"
"KiVEi"
"gTXZw"
"BhGTd"
"AiQEX"
"MHixI"
*/