$len beeing the length of a word. I always get only the first encounter but never all hits? Why is it so? I guess it has something to do with $len because without it I get all encounters. Thank you in advance.while($allseq =~ /(ct(?:a|g)a(?:c|t))(?:.{$len})/g) {push(@array, $1);}
In reply to Regex /g and interpolated lengths by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |