Don't forget to add the OFFSET portion of substr.my $string = 'some/very/varied_length/string'; my $subs = substr( $string, 0, length($string) - 6 ); say $subs;
In reply to Re: accessing a part of a string
by phenom
in thread accessing a part of a string
by uday_sagar
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |