[perl #126664] .roll on a Range of Num ain't random

2016-07-27 Thread Will Coleda via RT
On Fri Nov 27 09:22:20 2015, elizabeth wrote: > So implemented with 61ea661d8dfc04acabf1eb46c > > > Liz > > > On 27 Nov 2015, at 17:17, Patrick R. Michaud > > wrote: > > > > The standard meaning of ".roll" is to randomly select elements > > from a list. So I'd expect .roll on a Range to first

Re: [perl #126664] .roll on a Range of Num ain't random

2015-11-27 Thread Elizabeth Mattijsen
So implemented with 61ea661d8dfc04acabf1eb46c Liz > On 27 Nov 2015, at 17:17, Patrick R. Michaud wrote: > > The standard meaning of ".roll" is to randomly select elements > from a list. So I'd expect .roll on a Range to first convert the > Range to a list of values and then select from thos

Re: [perl #126664] .roll on a Range of Num ain't random

2015-11-27 Thread Patrick R. Michaud
The standard meaning of ".roll" is to randomly select elements from a list. So I'd expect .roll on a Range to first convert the Range to a list of values and then select from those. If the intent is to select from the values 0.1, 0.2, 0.3, I'd expect the programmer to write: (0.1, 0.2, 0.3).

Re: [perl #126664] .roll on a Range of Num ain't random

2015-11-27 Thread Moritz Lenz
On 11/26/2015 03:36 PM, Wenzel P. P. Peppmeyer wrote: On Thu, 26 Nov 2015, Elizabeth Mattijsen via RT wrote: (0.1 .. 0.3).roll(10).say; What did you expect? a selection of 0.1, 0.2, 0.3 ?? or 10 random values between 0.1 and 0.3 inclusive? I would (naive) expect 10x a value between 0.1

Re: [perl #126664] .roll on a Range of Num ain't random

2015-11-27 Thread Wenzel P. P. Peppmeyer
On Thu, 26 Nov 2015, Elizabeth Mattijsen via RT wrote: (0.1 .. 0.3).roll(10).say; What did you expect? a selection of 0.1, 0.2, 0.3 ?? or 10 random values between 0.1 and 0.3 inclusive? I would (naive) expect 10x a value between 0.1 and 0.3 . Analog to: (0.1, 0.2, 0.3).roll(10).say; #

Re: [perl #126664] .roll on a Range of Num ain't random

2015-11-26 Thread Elizabeth Mattijsen
> On 17 Nov 2015, at 19:16, Wenzel Peppmeyer (via RT) > wrote: > > # New Ticket Created by Wenzel Peppmeyer > # Please include the string: [perl #126664] > # in the subject line of all future correspondence about this issue. > # https://rt.perl.org/Ticket/Display.html?id=126664 > > > > (0.

[perl #126664] .roll on a Range of Num ain't random

2015-11-17 Thread via RT
# New Ticket Created by Wenzel Peppmeyer # Please include the string: [perl #126664] # in the subject line of all future correspondence about this issue. # https://rt.perl.org/Ticket/Display.html?id=126664 > (0.1 .. 0.3).roll(10).say; # OUTPUT«(0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1 0.1)␤» # I