programming in perl
i write it this way but its not working i dont know why
… and i didnt under stand your way of doing it
use strict;
# i am just writing this as an example to test my subroutine
my $firstSeq = "AGTUUUU";
my $secondSeq = "AGGG";
print "my result =", comparing ($firstSeq,$secondSeq),"\n";
sub comaring {
my $firstSeq = @_;
my $secondSeq = @_;
my $firtslength = length($firstSeq);
my $secondlength = length($secondSeq);
# can i do this? if (length($firstSeq) > length($secondSeq)){
if ($firtslength > $secondlength){
print "1 \n";
}
elsif ($firtslength == $secondlength){
print "0 \n";
}
elsif ($firtslength < $secondlength){
print "-1 \n";
}
}













compareSequences(seq1, seq2){
return (getSequenceLength(seq1) > getSequenceLength(seq2));
}