Re: string change problem

2004-03-30 Thread Muthukumar
PROTECTED]; [EMAIL PROTECTED] Sent: Monday, March 29, 2004 6:09 PM Subject: RE: string change problem news [EMAIL PROTECTED] wrote: : : I want to make a script which converts like : (pErl1234test = perl).I : wrote like : : #!/usr/bin/perl Always use the following two

Re: string change problem

2004-03-30 Thread Wiggins d Anconia
Please bottom post. Hello All, I am really very happy to receive the detailful response from you all.It is great. Thanks for all helping me to start my knowledge on PERL programming. 'perl' or 'Perl', never 'PERL'. perldoc -q 'Perl' http://danconia.org -- To unsubscribe,

string change problem

2004-03-29 Thread MuthuKumar
Hai all. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name $name =~ s/\W.*//; #change 1 $name =~ tr/A-Z/a-z/; #change 2

Re: string change problem

2004-03-29 Thread Smoot Carl-Mitchell
On Mon, 29 Mar 2004 15:05:34 +0530 MuthuKumar [EMAIL PROTECTED] wrote: Hai all. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name

Re: string change problem

2004-03-29 Thread James Edward Gray II
On Mar 29, 2004, at 3:35 AM, MuthuKumar wrote: Hai all. Howdy. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name You are missing semi-colons on all three

Re: string change problem

2004-03-29 Thread Flemming Greve Skovengaard
MuthuKumar wrote: Hai all. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name $name =~ s/\W.*//; #change 1 $name =~ tr/A-Z/a-z/;

Re: string change problem

2004-03-29 Thread WC -Sx- Jones
MuthuKumar wrote: Hai all. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name $name =~ s/\W.*//; #change 1 $name =~ tr/A-Z/a-z/;

Re: string change problem

2004-03-29 Thread Randy W. Sims
MuthuKumar wrote: Hai all. I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name $name =~ s/\W.*//; #change 1 $name =~ tr/A-Z/a-z/;

Re: string change problem

2004-03-29 Thread John W. Krahn
Muthukumar wrote: Hai all. Hello, I want to make a script which converts like (pErl1234test = perl).I wrote like #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name $name =~ s/\W.*//; #change 1 The \W character class includes every character that is NOT a-z and

Re: string change problem

2004-03-29 Thread Smoot Carl-Mitchell
On Mon, 29 Mar 2004 12:14:49 -0600 James Edward Gray II [EMAIL PROTECTED] wrote: On Mar 29, 2004, at 11:02 AM, Smoot Carl-Mitchell wrote: On Mon, 29 Mar 2004 15:05:34 +0530 MuthuKumar [EMAIL PROTECTED] wrote: $name =~ s/\W.*//; #change 1 This RE deletes zero or more

RE: string change problem

2004-03-29 Thread Charles K. Clarkson
news [EMAIL PROTECTED] wrote: : : I want to make a script which converts like : (pErl1234test = perl).I : wrote like : : #!/usr/bin/perl Always use the following two statements at the beginning of your scripts. They will help catch errors. use strict; use warnings; :

Re: string change problem

2004-03-29 Thread Jeff 'japhy' Pinyan
On Mar 29, MuthuKumar said: I want to make a script which converts like (pErl1234test = perl).I #!/usr/bin/perl print Enter ur name $name = STDIN $org_name = $name Those three lines are all missing semicolons. $name =~ s/\W.*//; #change 1

Re: string change problem

2004-03-29 Thread James Edward Gray II
On Mar 29, 2004, at 11:02 AM, Smoot Carl-Mitchell wrote: On Mon, 29 Mar 2004 15:05:34 +0530 MuthuKumar [EMAIL PROTECTED] wrote: $name =~ s/\W.*//; #change 1 This RE deletes zero or more non-alphanumeric characters followed by anything. So it deletes the entire string, since there was

RE: string change problem

2004-03-29 Thread Charles K. Clarkson
WC -Sx- Jones [EMAIL PROTECTED] wrote: : : MuthuKumar wrote: : : I want to make a script which converts : like (pErl1234test = perl). I wrote like : : #! /usr/bin/perl -w : : print Enter ur name; : my $name = STDIN; : my $org_name = $name; : $org_name =~ s/[^a-z]/ /gi; : $org_name

Re: string change problem

2004-03-29 Thread WC -Sx- Jones
Charles K. Clarkson wrote: WC -Sx- Jones [EMAIL PROTECTED] wrote: : : MuthuKumar wrote: : print Enter ur name; Sorry, Sx. That produces this: Org = perltest As Entered = pErl1234test The OP wanted: Org = perl As Entered = pErl1234test Sure, but Enter ur name could