in reply to Module for making english lists?
Yeah, pretty easy to write...
sub mkenglish { die 'arg required' if ! @_; if ( 1 == scalar @_ ) { return @_; } elsif ( 2 == scalar @_ ) { return join ' and ', @_; } else { my $last = pop @_; my $list = join ', ', @_; return "$list, and $last"; } }
You might also be interested in reading about the Serial comma.
|
|---|