>>>>> "JWK" == John W Krahn <[email protected]> writes:
JWK> Uri Guttman wrote: >>>>>>> "sw" == shawn wilson<[email protected]> writes: >> sw> my $data; >> sw> while ( my $line =<FILE> ) { >> sw> chomp ($line); sw> my @word = split / /, $line; >> >> sw> my $count = 0; sw> foreach my $aword ( @word ) { sw> $aword =~ tr/^[\-a-zA-Z]//; >> >> that isn't a good tr call/ it will not delete [] chars. those are not >> metachars in tr. tr is NOT a regex! JWK> It will not delete *any* characters. It will replace '^' with '^' and JWK> [' with '[' and '-' with '-' and 'a' through 'z' with 'a' through 'z' JWK> and 'A' through 'Z' with 'A' through 'Z' and ']' with ']'. yeah, i forgot he didn't have /d there. the whole thing gave me a headache! :) uri -- Uri Guttman ------ [email protected] -------- http://www.sysarch.com -- ----- Perl Code Review , Architecture, Development, Training, Support ------ --------- Gourmet Hot Cocoa Mix ---- http://bestfriendscocoa.com --------- -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] http://learn.perl.org/
