i have this gode to get the last 1000 bases of sequence but it's not working correctly.
my $ x_end = $end + 1000;
print "$x_end and $end\n";
my $sub = substr ($seq, $end, $x_end);
my $l = length $sub;
print $sub;
The length of sub should be 1000 but isn't I put the print lines n to check i wasn't being dopey, but i am! Why isn't this working as I'd expect?