21 lines
230 B
Perl
21 lines
230 B
Perl
|
#!/usr/bin/perl -w
|
||
|
|
||
|
$motif = shift(@ARGV);
|
||
|
# $motif=$ARGV[0]
|
||
|
#Shift
|
||
|
|
||
|
# Manière non explicite
|
||
|
while(<>)
|
||
|
{
|
||
|
print if(/$motif/);
|
||
|
};
|
||
|
|
||
|
# Manière explicite
|
||
|
#while($ligne = <>)
|
||
|
#{
|
||
|
# if($ligne =~ /$motif/)
|
||
|
# {
|
||
|
# print $ligne;
|
||
|
# }
|
||
|
#};
|