Create a gist now

Instantly share code, notes, and snippets.

#!/usr/bin/env perl
use strict;
use warnings;
use List::Util qw(shuffle);
my @name_list = qw(okkun kitak keoken gussan);
print join ', ', shuffle @name_list;
@kyanny
Owner
kyanny commented May 23, 2013

おれならこう書く

  • use PACKAGE qw(インポートしたい関数名)
  • qw( ... ) 配列リテラル
  • シャッフル結果を一時変数に入れる必要は無い
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment