Re: grep mystery / What happened to my @ sign ?

2005-11-22 Thread Jeremy Kister
On 11/23/2005 2:26 AM, David Gilden wrote: > $SendersEmail ="[EMAIL PROTECTED]"; > > ($SendersEmail) = $SendersEmail =~ m/([EMAIL PROTECTED],60})/; [...] > I was expecting this: [EMAIL PROTECTED] > What happened to my @ sign ? you'll notice that not only is the @ missing, but '@earthlink' is mis

grep mystery / What happened to my @ sign ?

2005-11-22 Thread David Gilden
Greetings, #!/usr/bin/perl $SendersEmail ="[EMAIL PROTECTED]"; ($SendersEmail) = $SendersEmail =~ m/([EMAIL PROTECTED],60})/; print "$SendersEmail\n"; prints: someone.lastname.net I was expecting this: [EMAIL PROTECTED] What happened to my @ sign ? Thanks! Dave Gilden Visit my schedule

Re: download a protein sequence from the web using LWP module

2005-11-22 Thread Suvajit Sengupta
Please avoid posting these kind of requests. The forum is here to sort out our problems, not to solve your homework !! Regards, Suvajit [EMAIL PROTECTED] wrote: SET A 1. Write a perl script to find the number of spaces in a given sentence using regular expression. 2. Write a perl

Re: number of spaces in a given sentence using regular expression.

2005-11-22 Thread Paul Johnson
On Tue, Nov 22, 2005 at 10:36:49PM +, [EMAIL PROTECTED] wrote: > SET A > 1. Write a perl script to find the number of spaces in a given sentence > using regular expression. > please give me the answers of these questions. I only have time to do this one for now. Maybe others will be

Alternative use of the Authen::Captcha module

2005-11-22 Thread Mike Blezien
Hello, Is this are alternative method similar to the Authen/Captcha modules which generate evertime the form loads a random group of alpha/numeical characters and will change the font color,size,background and distortion of characters, or does one need to create all their own images to be used

Re: number of spaces in a given sentence using regular expression.

2005-11-22 Thread Bob Showalter
[EMAIL PROTECTED] wrote: ... please give me the answers of these questions. Chris Devers will be along shortly... :~) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: download a protein sequence from the web using LWP module

2005-11-22 Thread JupiterHost.Net
Please stop double posting your homework requests. [EMAIL PROTECTED] wrote: SET A 1. Write a perl script to find the number of spaces in a given sentence using regular expression. 2. Write a perl script to take name from command line argument and print the inputted name in both l

Re: number of spaces in a given sentence using regular expression.

2005-11-22 Thread JupiterHost.Net
[EMAIL PROTECTED] wrote: SET A 1. Write a perl script to find the number of spaces in a given sentence using regular expression. 2. Write a perl script to take name from command line argument and print the inputted name in both lower case and upper case. (use functions) 3.

Re: ALARM

2005-11-22 Thread Jay Savage
On 11/22/05, Tom Allison <[EMAIL PROTECTED]> wrote: > John Doe wrote: > > Tom Allison am Dienstag, 22. November 2005 12.24: > > > >>I figured out I can do this: > >> > >>eval { > >> local $SIG{ALRM} = sub { warn("alarm\n") }; > >> alarm 1; > >> for(my $j = 0; $j < 1_000_000, $j++) {

RE: number of spaces in a given sentence using regular expression.

2005-11-22 Thread Timothy Johnson
No. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 22, 2005 2:37 PM To: beginners@perl.org Subject: number of spaces in a given sentence using regular expression. SET A 1. Write a perl script to find the number of spaces in a giv

download a protein sequence from the web using LWP module

2005-11-22 Thread [EMAIL PROTECTED]
SET A 1. Write a perl script to find the number of spaces in a given sentence using regular expression. 2. Write a perl script to take name from command line argument and print the inputted name in both lower case and upper case. (use functions) 3. Write a perl script to evaluat

number of spaces in a given sentence using regular expression.

2005-11-22 Thread [EMAIL PROTECTED]
SET A 1. Write a perl script to find the number of spaces in a given sentence using regular expression. 2. Write a perl script to take name from command line argument and print the inputted name in both lower case and upper case. (use functions) 3. Write a perl script to eva

Re: ALARM

2005-11-22 Thread John Doe
Tom Allison am Dienstag, 22. November 2005 20.59: > John Doe wrote: > > Tom Allison am Dienstag, 22. November 2005 12.24: > >>I figured out I can do this: > >> > >>eval { > >>local $SIG{ALRM} = sub { warn("alarm\n") }; > >>alarm 1; > >>for(my $j = 0; $j < 1_000_000, $j++) { > >>

Re: ALARM

2005-11-22 Thread Tom Allison
John Doe wrote: Tom Allison am Dienstag, 22. November 2005 12.24: I figured out I can do this: eval { local $SIG{ALRM} = sub { warn("alarm\n") }; alarm 1; for(my $j = 0; $j < 1_000_000, $j++) { my $x = log(rand()*1000+1); } alarm 0; }; if

RE: Replacing a Bracketed String with "N"

2005-11-22 Thread Cintron, Jose J.
Try this one... $str = "AABBE[TH]AODD[AAAB]AQA"; $str =~ s/\[[A-Z]*\]/N/g; print "$str\n\n"; +-- | José J. Cintrón - <[EMAIL PROTECTED]> +-- > -Original Message- > From: Edward Wijaya [mailto:[EMAIL PROTECT

Re: Replacing a Bracketed String with "N"

2005-11-22 Thread Jeff 'japhy' Pinyan
On Nov 22, Edward Wijaya said: $str1 = "ATC[TG]CC"; # into $ans_str1 = "ATCNCC"; $str2="ATC[TG]CCGC[ACTG]"; #into $ans_str2="ATCNCCGCN"; The simplest way I can think of is $string =~ s/\[[ACTG]+\]/N/g; which is very explicit: it replaces a '[' followed by A's, C's, T's, and/or

Replacing a Bracketed String with "N"

2005-11-22 Thread Edward Wijaya
Hi, Is there a fast way to replace string like this: $str1 = "ATC[TG]CC"; # into $ans_str1 = "ATCNCC"; #and $str2="ATC[TG]CCGC[ACTG]"; #into $ans_str2="ATCNCCGCN"; Thus, the position of the bracket can be in any positions with any number, and number of strings enclosed by the brac

Re: Perl + OpenSSL

2005-11-22 Thread Ing. Branislav Gerzo
[EMAIL PROTECTED] [WPF], on Monday, November 21, 2005 at 15:59 (-0600) typed: you have that in that faq. So try again: $out = `echo this should work, nah`; -- How do you protect mail on web? I use http://www.2pu.net [We really don't care how Michael does it in Hollywood!] -- To unsubscrib

Re: local $/ = '';

2005-11-22 Thread Jay Savage
On 11/21/05, John W. Krahn <[EMAIL PROTECTED]> wrote: > Brian Volk wrote: > > Hi All~ > > Hello, > > > I'm trying to get my head around local $/ = ''; #enable paragraph mode. > > Did you read the documentation for it in perlvar.pod? > > perldoc perlvar > > Is there anything in the documentation tha

Re: HTML::TokeParser, get HTML

2005-11-22 Thread Ing. Branislav Gerzo
Ing. Branislav Gerzo [IBG], on Tuesday, November 22, 2005 at 13:42 (+0100) thinks about: IBG> while(my $tag = $parser->get_tag('b')) { IBG> my $text = $parser->get_text(); IBG> last if $text =~ /^(this and that|or that and this)/i; IBG> } IBG> my $text = $parser->get_text('b', 'b

HTML::TokeParser, get HTML

2005-11-22 Thread Ing. Branislav Gerzo
Hello all, I'm using this great module for parsing HTML files. But I run into trouble - I need get clear unchanged HTML code. Common example of using this module is (snippet): while(my $tag = $parser->get_tag('b')) { my $text = $parser->get_text(); last if $text =~ /^(this and t

Re: ALARM

2005-11-22 Thread John Doe
Tom Allison am Dienstag, 22. November 2005 12.24: > I figured out I can do this: > > eval { > local $SIG{ALRM} = sub { warn("alarm\n") }; > alarm 1; > for(my $j = 0; $j < 1_000_000, $j++) { > my $x = log(rand()*1000+1); > } > alarm 0; > }; > if ( $@ ) { >

ALARM

2005-11-22 Thread Tom Allison
I figured out I can do this: eval { local $SIG{ALRM} = sub { warn("alarm\n") }; alarm 1; for(my $j = 0; $j < 1_000_000, $j++) { my $x = log(rand()*1000+1); } alarm 0; }; if ( $@ ) { carp "[EMAIL PROTECTED]"; } Which is very similar

RE: local $/ = '';

2005-11-22 Thread Brian Volk
-Original Message- From: Tom Allison [mailto:[EMAIL PROTECTED] Sent: Saturday, November 19, 2005 4:43 PM To: Brian Volk Cc: 'beginners@perl.org' Subject: Re: local $/ = ''; Brian Volk wrote: > Hi All~ > > > > I'm trying to get my head around local $/ = ''; #enable paragraph mode. >