Leser: 2
4 Einträge, 1 Seite |
1 2 3 4 5 6 7 8 9 10 11 12
my @array = (); my @array_row; push (@array, "$x $y $z $E"); for my $j(0..$#array) { @array_row = split(' ', $array[$j]); #print "$array_row[3]\n"; # gibt $E aus #print @array; #alle $x, $y, $z und $E ausgeben }
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#!/usr/bin/perl use strict; use warnings; use Data::Dumper; use utf8; my @array = ( [ qw/ david raab 24 3 / ], [ qw/ anne schmidt 23 1/ ], [ qw/ manuel montero 24 2/ ], ); @array = sort { $a->[3] <=> $b->[3] } @array; print Dumper \@array;
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
$VAR1 = [
[
'anne',
'schmidt',
'23',
1
],
[
'manuel',
'montero',
'24',
2
],
[
'david',
'raab',
'24',
3
]
];
4 Einträge, 1 Seite |