Thanks for the insight. I'm ignorant of the secrets of lookahead,
lookbehind, inner repetitions, and all the other associated
voodoo with things like this, so while this regex certainly
works, the breakdown of what it all means is a mystery to
me. Would "Mastering Regular Expressions" be a good
teacher for this sort of thing?
Thanks, merlyn (++), and everybody else for their help and insight.
Comment on (Kozz) RE: RE: regexp for adding commas to a number
The currently available Mastering Regular Expressions doesn't cover any of the really cool Perl 5 regex stuff. Jeffrey Friedl is in the process of rewriting
the book for a second edition, and has been working with the Perl developers to
uncover inconsistencies in the implementation (what normal people would
call "bugs" {grin}) and gaps in the documentation.
Don't hold your breath though. I know this effort will probably take one to two
years of nights and weekends. "Been there Done that" x $n