Changing template parameters

Jack Stouffer via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Jan 16 07:56:16 PST 2017


On Monday, 16 January 2017 at 15:32:33 UTC, Dlearner wrote:
> Hey, quick question!
>
> I'm messing around with std.random and noticed that you can 
> change the boundaries parameter to be either open or closed 
> intervals on either side.  By default it is "[)".  How do I 
> change these template parameters?

Same way you use any template parameters,

      auto i = uniform!("(]")(0, 1000);


More information about the Digitalmars-d-learn mailing list