Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Reading a particular values from the file.

by anniyan (Monk)
on Nov 23, 2005 at 14:12 UTC ( #511095=note: print w/ replies, xml ) Need Help??


in reply to Reading a particular values from the file.

anushya, If i understood your question correctly, instead of if you use while

while ($num =~ m/<member-id>(\d+)/g){ push (@val, $1);} print "@val\n";

Also you can assign the $1 value to a string $val rather to an array @val.

while ($num =~ m/<member-id>(\d+)/g){ $val = $1; print $val,"\n";}

or simply

@num = $num =~ m/<member-id>(\d+)/g;

I think this is your first posting, welcome to the Monastery, use <c> tag for coding part.

updated

Regards,
Anniyan
(CREATED in HELL by DEVIL to s|EVILS|GOODS|g in WORLD)


Comment on Re: Reading a particular values from the file.
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://511095]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (17)
As of 2014-12-18 16:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (58 votes), past polls