Steven D'Aprano wrote: > Good luck with the question! If you do solve it, please come back and > tell us how you did it. I for one am curious now whether or not it can > be done using Python regexes. Perhaps someone else might have a > solution. You could try the python-l...@python.org mailing list, also > available on comp.lang.python on Usenet.
Dinara, here's a hint: I found a brute-force solution where the regex contains every allowed letter explicitly, followed by a quantifier. As long as you confine yourself to ascii-letters the performance may be acceptable. If that hurts your sense of esthetics the tip to try comp.lang.python is a good one. Matthew Barnett aka MRAB, author of an alternative regex library for python, posts there regularly. _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor