>     while (<DATA>) {
>         print if /[.?]$/;
>     }
>     __DATA__
>     This is a test.
>     Is this another test?
>     This doesn't print!

That character class should have been "[.,?]", since a comma was apparently desired.

Also, the dot, comma, and question mark do not need to be escaped in a character class.

Cheers,
Curtis "Ovid" Poe

=====
Senior Programmer
Onsite! Technology (http://www.onsitetech.com/)
"Ovid" on http://www.perlmonks.org/

__________________________________________________
Terrorist Attacks on U.S. - How can you help?
Donate cash, emergency relief information
http://dailynews.yahoo.com/fc/US/Emergency_Information/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to