using the full range of ubyte with iota
Dominikus Dittes Scherkl via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sat Jan 24 14:57:57 PST 2015
On Saturday, 24 January 2015 at 21:00:06 UTC, Tobias Pankrath
wrote:
> On Saturday, 24 January 2015 at 20:49:03 UTC, Dominikus Dittes
> Scherkl wrote:
>> I would have no problem using an explicit cast, but where
>> should I apply it?
>
> iota(0, 256).map!(x => foo(cast(ubyte) x))
Ok, thank you very much.
4 times exactly the same answer - seems to be a common solution
to a well known problem. :-/
More information about the Digitalmars-d-learn
mailing list