Skip to content

Instantly share code, notes, and snippets.

@kyanny
Created May 23, 2013 01:43
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kyanny/5632249 to your computer and use it in GitHub Desktop.
Save kyanny/5632249 to your computer and use it in GitHub Desktop.
#!/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
Copy link
Author

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