Re: [go-nuts] Re: Shuffle Items in a Slice

2016-06-28 Thread Kaveh Shahbazian
Thanks for the reference! BTW I love this behaviour! On Tue, Jun 28, 2016, 00:14 Chris Hines wrote: > The history of this behavior is explained in the release notes for Go 1.3: > https://golang.org/doc/go1.3#map > > > On Friday, June 24, 2016 at 8:48:20 AM UTC-4, Val wrote: >> >> 2 implementatio

[go-nuts] Re: Shuffle Items in a Slice

2016-06-27 Thread Chris Hines
The history of this behavior is explained in the release notes for Go 1.3: https://golang.org/doc/go1.3#map On Friday, June 24, 2016 at 8:48:20 AM UTC-4, Val wrote: > > 2 implementations here : > http://www.programming-idioms.org/idiom/10/shuffle-a-list/1564/go > > As for the map iteration trick

Re: [go-nuts] Re: Shuffle Items in a Slice

2016-06-26 Thread Martin Geisler
Hi Val On Fri, Jun 24, 2016 at 2:48 PM, Val wrote: > 2 implementations here : > http://www.programming-idioms.org/idiom/10/shuffle-a-list/1564/go > > As for the map iteration trick, the runtime doesn't guarantee to randomize > anything, although it often tries to, so developers don't rely on some

[go-nuts] Re: Shuffle Items in a Slice

2016-06-24 Thread Val
2 implementations here : http://www.programming-idioms.org/idiom/10/shuffle-a-list/1564/go As for the map iteration trick, the runtime doesn't guarantee to randomize anything, although it often tries to, so developers don't rely on some specific order. I've seen (in the past) some map iteration