Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: RFC: Kinda pseudo-shuffle using sort

by rsFalse (Chaplain)
on Mar 16, 2021 at 09:29 UTC ( #11129750=note: print w/replies, xml ) Need Help??


in reply to Re: RFC: Kinda pseudo-shuffle using sort
in thread RFC: Kinda pseudo-shuffle using sort

Nice alternative!

Though it can be used with simple arrays only (containing text and numbers, not references).

I did the same "histogram" here with '$pseudoshuffle_with_hash'. And I'm getting different results every time, because 'srand(CONST)' doesn't influence hash. But outputs are similar. Kinda symmetric. I paste here two runs:

3) A A A . . . C C C C C . . . . . E E E . . . G G G G G . . . . . . . . +. . I I I I I A A A A A . . . C C C C C C C C C C E E E . . . . . G G G G G I I I I +I I I I I A A A . . . . . C C C C C . . . . . E E E E E . . . . . . . . . . . . +I I I I I A A A A A . . . . . . . . . . . . . . E E E E E . . . . . G G G G G G +G G G A A A A A A A A A A . . . . . E E E E E . . . . . . . . . G G G G G G +G G G G A A A A A . . . . . . . . . . . . . . . . . . E E E E E E E E E E . . +. . . A A A . . . C C C C C . . . . . E E E . . . G G G G G . . . . . . . . +. I I I I I A A A A A . . . C C C C C C C C C C E E E . . . . . G G G G G I I I I +I I I I I A A A . . . . . C C C C C . . . . . E E E E E . . . . . . . . . . . . +. I I I I I
3) A A A A A . . . C C C . . . E E E E E . . . G G G G G . . . . . I I I +I I I I I I I A A A A A . . . . . . . C C C C C C C C . . . . . E E E E E . . . . . +. . . . . . . . . . . . C C C C C C C . . . . . . . . . . G G G G G G G G G . . +. . . A A A A A . . . C C C . . . . . E E E E E . . . . . . . . . . I I I I +I I I I I I A A A A A A A A A A . . . . . E E E E E E E E E E . . . . . G G G G G +G G G G A A A A A . . . C C C . . . . . E E E E E . . . . . . . . . . I I I I +I I I I I . . . . . . . C C C C C C C . . . . . . . . . . G G G G G G G G G G . +. . . . A A A A A . . . . . . . C C C C C C C . . . . . E E E E E . . . . . . +. . . . A A A A A . . . C C C . . . E E E E E . . . G G G G G . . . . . I I I +I I I I I I

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11129750]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2022-08-10 01:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?