Working with ranges

Murilo murilomiranda92 at hotmail.com
Sat Dec 8 03:37:56 UTC 2018


Hi guys, I have created an array of strings with "string[12] ps = 
["cat", "dog", "lion", "wolf", "coin", "chest", "money", "gold", 
"A", "B", "C", "D"];".


I want to use the array as a range and I want to randomize it, 
like I want to transform that into several other ranges with the 
same elements but in different orders, how do I do that?

I tried using the function choice() from std.random but it gives 
an error message for some reason.


More information about the Digitalmars-d-learn mailing list