#! /usr/bin/perl -w use strict; use warnings; use feature qw(say); my @hoge = (0, 1, 2, 3); say join( ", ", listdouble(@hoge) ); sub listdouble { my @list = @_; return map { $_ * 2 } @_; }