> "ta" == timothy adigun <2teezp...@gmail.com> writes:
ta> You can use unpack:
ta>$val = "11.0.56.1";
ta>$new_val=unpack("x5 A2",$val); # skip forward 6, get 2
ta> print $new_val # print 56;
unpack would be a poor choice if the number of digits in a field
changes. pac
On Sun, 11 Sep 2011 02:32:58 +0200
Paul Johnson wrote:
> On Sat, Sep 10, 2011 at 04:35:07PM -0700, Rajeev Prasad wrote:
>
> > Hi
> >
> > i am planning to use this module, but its version is 0.11 ! and author says
> > it is beta quality. i am using Net::OpenSSH which is also below ver 1.0
> >
Hi Irfan,
You can use unpack:
$val = "11.0.56.1";
$new_val=unpack("x5 A2",$val); # skip forward 6, get 2
print $new_val # print 56;
On Sat, Sep 10, 2011 at 04:35:07PM -0700, Rajeev Prasad wrote:
> Hi
>
> i am planning to use this module, but its version is 0.11 ! and author says
> it is beta quality. i am using Net::OpenSSH which is also below ver 1.0 but
> i have had no issues with it so far.
>
> does anyone have any goo
Hi
i am planning to use this module, but its version is 0.11 ! and author says it
is beta quality. i am using Net::OpenSSH which is also below ver 1.0 but i
have had no issues with it so far.
does anyone have any good/bad experience with this module?
thank you.
Rajeev
On 10/09/2011 18:23, Irfan Sayed wrote:
hi,
i have following string.
$val = "11.0.56.1";
i need to write regular expression which should match only "56" and print
please suggest
I think you should forget about regular expressions and use split:
my $sub = (split /\./, $val)[2];
HTH,
On 11-09-10 01:23 PM, Irfan Sayed wrote:
i have following string.
$val = "11.0.56.1";
i need to write regular expression which should match only "56" and print
please suggest
( $val =~ /(56)/ ) && print $1;
--
Just my 0.0002 million dollars worth,
Shawn
Confusion is the first st
Hi Irfan,
On Sat, 10 Sep 2011 10:23:31 -0700 (PDT)
Irfan Sayed wrote:
> hi,
>
> i have following string.
>
> $val = "11.0.56.1";
>
> i need to write regular expression which should match only "56" and print
>
There are any number of ways to extract "56" using a regular expression from
hi,
i have following string.
$val = "11.0.56.1";
i need to write regular expression which should match only "56" and print
please suggestÂ
regards
irfan