James Edward Gray II wrote:
···
On Sep 30, 2007, at 8:47 AM, 7stud -- wrote:
Ruby also relies heavily on regex's, and regex's are never going to be
easy to read for anyone. regex's are not beginner friendly, and that
might be a big barrier for a beginner trying to learn ruby. There are
lots of people who just can't learn regex's.I'm staying out of the Ruby vs. Python debate, but the above is just plain wrong and I wish people would stop saying things like this.
For some reason, regular expressions are surrounded in this aura of mystery. Perhaps their syntax heavy nature makes them seem odd to people unfamiliar with them at first glance, but for some reason many, many people believe things like the comment posted about. That's a real shame.
Regular expression is a simple pattern language anyone can learn quite easily. I once taught them to my wife in the space of evening, to help with a work project. She's an above average skill-level computer user, but definitely not a programmer. She had no trouble grasping the concepts and still uses regular expression to this day.
Please, sit down and really try learning regular expression before adding to the fear factor surrounding them. I promise, it's time well spent.
James Edward Gray II
+1
BTW ... I *still* hate them, but I use them.