1 A
0 B
3 C
0 A
2 C
5 A
3 E
1 E
####
6 A
0 B
5 C
4 E
####
#!/usr/bin/perl
use strict;
use warnings;
##################################
## ARGUMENTS OF THE SCRIPT
##################################
# the argument due to be used is
# the ALL_FT file
#####################################
# do not forget the $ before the ARGV
#####################################
# the format of the ALL_FT file has to be : $date.ALL_FT (ex: 20060904.ALL_FT)
my $ALL_FT_file = "$ARGV[0]";
################# END OF THE DECLARATION OF THE ARGUMENTS
my $Current_Dir = `pwd`;
# print STDOUT "the current directory is $Current_Dir";
# name of the OUTFILE
# the day appears in the name of the OUTFILE
my $day = $ALL_FT_file;
# the following command is used to skip the .ALL_FT in the name of the ALL_FT_file
# and thus to have the date
$day =~ s/.ALL_FT//;
# open the ALL_FT file
open(INFILE,"unique_delay_${day}.csv") ;
# creation of a table
my @New_Table;
while () {
# the lines are composed of elements separated by a point comma
my $Line = $_;
chomp($Line);
my @Elements = split(";", $Line);
push(@New_Table, $Elements[2]);
}
print @New_Table;
my %Hash = map { $_, 1 } @New_Table;
my @unique = keys %Hash;
close INFILE;
close OUTFILE;