Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

C# random multiple of 5 in range

var random = new Random();

int rand = random.Next(0, 12); 	// for a resulting range of 0 to 60 
int scaledRand = rand * 5;		// in multiples of 5
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #random #multiple #range
ADD COMMENT
Topic
Name
6+1 =