use List::Util qw/shuffle/; my @order = shuffle qw/ continue 0 next 1 redo 2 last 3 /;