#!/usr/bin/perl use warnings; use strict; use feature qw{ say }; use List::Util qw{ shuffle }; my @words = qw( this is my string ); my @order = 0 .. $#words; my %ord; @ord{@words} = 0 .. $#words; @words = shuffle(@words); @order = @ord{@words}; print do { local $" = "\t"; "@words\n", "@order\n" }; say join ' ', map $words[$_], sort { $order[$a] <=> $order[$b] } @order;
($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,
In reply to Re^4: keep track of array indexes
by choroba
in thread keep track of array indexes
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |