|< 1 2 >| | 13 Einträge, 2 Seiten |
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/perl
use strict;
use warnings;
my $lastline = '';
while (<>) {
if (m~ROT~ or $lastline =~ m~ROT~) {
print;
}
$lastline = $_;
}
1
2
3
4
5
6
7
8
9
10
#!/usr/bin/perl
use strict;
use warnings;
open(F, "file.txt") or die $!;
my @file = <F>;
close(F);
@file = sort{$a cmp $b} @file;
print @file;
1
2
3
my @array = ("A", "B", "Z", "F", "c", "H", "8");
print join(' ', sort { $a cmp $b } @array), "\n";
1
2
3
4
5
6
7
8
9
10
#!/usr/bin/perl
use strict;
use warnings;
my $lastmatch = 0;
while (<>) {
my $match = m~ROT~;
print if $match or $lastmatch;
$lastmatch = $match;
}
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/perl
use strict;
use warnings;
my $lastline = '';
while (<>) {
if (m~ROT~ or $lastline =~ m~ROT~) {
print;
}
$lastline = $_;
}
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/perl
use strict;
use warnings;
my $lastline = '';
while (<>) {
if (m~ROT~ or $lastline =~ m~ROT~) {
print;
}
$lastline = $_;
}
|< 1 2 >| | 13 Einträge, 2 Seiten |