function to generate random number 28typescript 29

Solutions on MaxInterview for function to generate random number 28typescript 29 by the best coders in the world

showing results for - "function to generate random number 28typescript 29"
Violeta
13 May 2017
1/**
2* Gets random int
3* @param min 
4* @param max 
5* @returns random int - min & max inclusive
6*/
7getRandomInt(min, max) : number{
8	min = Math.ceil(min);
9	max = Math.floor(max);
10	return Math.floor(Math.random() * (max - min + 1)) + min; 
11}