Tim Johnson wrote:
Gunnar Hjalmarsson wrote:
Tim Johnson wrote:
Chetak Sasalu wrote:

<regex suggestion snipped>

That is one way to do it, but maybe you should tell him what it
 is that the regex does.  I remember from my newbie days that
it wasn't too useful when people just threw regexes at me
without explaining them because they look so daunting before
you are used to them.

Chetak *could* have done so, but doing it is certainly nothing you can claim that he *should* do. What *should* happen is that the OP ("Jack Jack") start studying some appropriate documentation, ...

I didn't say that Chetak's reply was wrong, or that he was somehow remiss in omitting that information.

I did understand your response as if you implied the latter. My apologies if I was wrong.

But here's where we differ:  Regular expressions are quite possibly
one the hardest part of learning effetive Perl programming,and
arguably the most valuable.  Handing someone a finished regular
expression without explaining how it works doesn't really help
someone learn how to make their own regular expressions.

I would say that nobody can learn regular expressions without serious own efforts. To somebody who is seriously trying to learn, I believe that a finished regex *can* be helpful in the learning process, since it serves the purpose of pointing the questioner in the right direction. Personally I learned regexes basically by studying finished Perl programs while using the docs to figure out what was happening.

When helping somebody understand regexes, it's often pretty easy to
simply show how a problem can be solved. Adding comments that explain
every single detail is harder and much more time-consuming. If
somebody wants to do it, it's excellent, but the point I was trying to
make is that you can't expect that. The natural way IMO is that the
questioner seeks the explanations in the docs. (A pointer to relevant
docs is always a good idea, though.)

You maintained that if he really enjoyed the fish he was given and wanted another one bad enough, he would have gone out and found a book on fish and from there derived that fishing would have been the approprate way to get a fish, studied up on it and come back when he had problems fishing

Yes, I did. I was assuming that one single fish will only still his hunger temporarily, and that he realises that he needs to learn how to fish. ;-)

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl


-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to