in reply to Removing spaces, again.

It looks like you are just matching, rather than substituting. Try
($BKSIC_MODEL[$i] = substr ($line, 3, 7)) =~ s/^\s*(\S*)\s*$/$1/;

Dave

UPDATE
My mistake. Forgot my parens around $BKSIC_MODEL[$i] = substr ($line, 3, 7). Fixed now.

Replies are listed 'Best First'.
Re: Re: Removing spaces, again.
by merlyn (Sage) on Mar 16, 2001 at 01:50 UTC
      I think s/// return the number of modifications issued. Using s/// whitout g modificator, result to return true/false but... saying 0/1 is more sharp ( scuse me for this effrontery master ;)

      _______________________
      Please, don't hurt me !