http://www.perlmonks.org?node_id=967100


in reply to How can I count the number and kinds of letters at 1st, 2nd and 3rd positions of 3-letter words in a string?

I've noticed the trend in your posts:

When I see that many questions on virtually the same topics (bioinformatics, strings, regular expressions), with little change in level of understanding of the Perl tools between posts, I start to think one of two things is at play here. Either this individual is just letting us solve his problems for him (I'm happy to dismiss this possibility for now, as just me being grumpy), or this individual needs not just an answer to his immediate question, but help learning the tools better so that he'll be better equipped to solve such problems on his own. Perhaps you really haven't been shown where to find the best information on the topics you're inquiring about. That's our fault, so here goes:

There are a number of free sources of information on regular expressions: perlrequick, perlretut, perlre.

Sources of information on conditionals and looping: perlintro, perlsyn

Sources of information on the substr function: substr.

Books about Bioinformatics, and using Perl to solve Bioinformatics problems: Beginning Perl for Bioinformatics, Mastering Perl for Bioinformatics, Developing Bioinformatics Computer Skills.

And I shouldn't forget to mention these gems: Learning Perl, and Mastering Regular Expressions.

There are many other books out there, but I picked these ones to help you narrow down the haystack to a few needles that will be most beneficial to you right now.

I think it would be accurate to say that if you were to spend a few hours with perlintro, perlrequick, perlretut, and substr, you would save yourself many more hours of trouble-shooting time in the longrun... time well spent. Furthermore, if you were to pick one or two of the books from the list above and spend a week or two with it, as well as a few days with all of the POD I linked to, you could become one of the Monastery's stronger Bioinformatics fonts of wisdom.


Dave