1var min = 10000;
2var max = 90000;
3var num = Math.floor(Math.random() * min)) + max;
4
5here you can increse the min and max value this is for 5 digits
6
7
8or this
9Math.floor(Math.random()*90000) + 10000;
10
1var seq = (Math.floor(Math.random() * 10000) + 10000).toString().substring(1);
2console.log(seq);