[Tutor] please return flys in ointment
ALAN GAULD
alan.gauld at btinternet.com
Sun Jul 7 03:01:04 CEST 2013
>Oddly, I was just looking at pyparsing, and it mentioned it's good for Python 2.3
>and above. But that left me thinking "Do they mean version 3 and above?"
>since a lot is not ready for version 3. Since we know a lot has changed since 2.3 and especially since 2.3 I'd take it with
a pinch of salt and consider it v2 safe.
But if it says 2.7 and above it should be v3 safge too since v2.7 allows pretty good
portability between 2 and 3.
But thats just me...
BTW, I understand the basics of regexes, but had some problems and looked
>into pyparsing. Has anyone used that and does it seem better than regexes,
>or easier on the noggin?When searching for text use simple string searches where possible.
If not possible use regexes where the input and/or search string are unstructured.
If its structured use a parser for preference. (HTML, XML or pyparser etc for
proprietary type stuff)
There are a few things where regexes are the best tool, but for anything
non-trivial (relatively speaking!) there is usually a better way... IMHO...
Alan g.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20130707/50e09423/attachment.html>
More information about the Tutor
mailing list