Bash ~ Perl ~ Python ~ Batch ~ Ruby
Thursday, 23 May 2013
storing two or more output in same variable in perl
open(FILE,"/etc/passwd");
while($line=<FILE>)
{
if($line=~/sshd|sam/)
{
$r.=$line;
}
}
close(FILE);
print $r;
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment