Folks,

Simple question:
Is there a more elegant way to express this:
  an array of names is converted into a comma-separated list.
  if the list gets to long - limit it and add ", etc." at the end.

      $str = join ', ', @names;
      if (length($str)>90) {
        ($str = substr($str,0,90)) =~ s/,[^,]*$/, etc./;
      }

Warmest Regards, 
Lev Selector, New York

Reply via email to