something...; something...; my @X = &values(); sub value{ open (R, "input") || die...; something..; something..; my @Y = ( ); return @Y; }