maxstr
maxstr @list
Similar to max
, except
that maxstr
treats all list
items as strings. maxstr
will
return the “highest string” as determined by the gt
operator. As always, if list is
empty, maxstr
returns undef
.
my @ll = qw(1 3 5 nate Person pizza man carl_everett dinosaur); my $max_s = maxstr(@ll); print "$max_s "; # Prints 'pizza'
3.23.130.191