I'm sorry you feel that my question was inappropriate. I'm not too sure how I can ask the question without context though?
I don't understand how $seq is not meeting the if condition when everything else is.

What precisely is your question? A long time ago Ovid wrote this reply: Clean your room. If you take the time to make your question easy to read, then others will give the time to help you find the solution.

Dear Jeffa,
Thanks for taking the time to reply. I am very much a beginner, and still learning the ropes. I am not very au fait with the "tidy" etiquette of perl yet. I will have a look at Perl Tidy and make sure I improve my scripting technique.
Many thanks, E

Since this is a question regarding why your if condition is unexpectedly true, collect some sample cases where it is not behaving as expected.

Since you are doing a simple regex test against a single value, your question likely boils down to "Why does this string get matched by this regex?"

if ($strands{$ID[$i]} =~ m/\+/) { That regex matches any string containing a '+' anywhere in it. In the case where you think it should NOT match but is matching, print out the string $strands{$ID[$i]} (not just $ID[$i] as your comment implies) and see what it contains.

Appended:

I notice at the top you are checking if '-', elsif '+', but at the bottom of your code, you are checking if '+' elsif '-'. If you have a string that contains both a + and a -, that may be causing some confusion.

Dear Poj,
I have another subroutine that I call later that pulls out a sequence of length = 9, and this works absolutely fine. I have replied to suicidejunkie and have worked out the errors of my ways! - El