in reply to Chop command that removes the first character

EDIT: I was thinking chomp, my bad. The only real possibility is the following, then:
$varname = substr($varname, 1);

Replies are listed 'Best First'.
Re^2: Chop command that removes the first character
by mawe (Hermit) on Oct 26, 2004 at 08:03 UTC
    Hi!

    Chop removes only whitespace...

    What you mean is chomp. chop removes any character.

    EDIT: TedPride: Please don't just delete what you wrote. Now nobody knows what I have been talking about ... as usual :)

    mawe

      Because you have quoted it we know what was there. As a minor pedant chomp will remove any char that corresponds to $/ aka the $INPUT_RECORD_SEPARATOR. For example if you undef $/ but don't localise (or restore) it chomp will mysteriously fail. Not only that it is a global.....

      cheers

      tachyon