数据t转换
#!/usr/bin/perl
use strict;
use warnings;
open my $fh,"a.out";
open OUT,">a_t.out";
my (@array,$i,$j,$value);
while (<$fh>){
my @temp = split;
push @array,\@temp;
}
my $colum = $#{$array[0]}+1;
my $line= @array;
for ($i=0;$i<$colum;$i++) {
for ($j=0;$j<$line;$j++) {
$value=$array[$j][$i];
print OUT $value,"\t";
}
print OUT "\n";
}
close OUT;