On Jan 22, 2008 10:56 PM, Vahid Moghaddasi <[EMAIL PROTECTED]> wrote:
> On Jan 22, 2008 9:31 PM, Chas. Owens <[EMAIL PROTECTED]> wrote:
> >
> > Off hand I think that would only happen if the user name or the uid
> > was the same for some of your users. Can you present a cleaned up
> > version of y
On Jan 22, 2008 10:55 PM, Jeff Pang <[EMAIL PROTECTED]> wrote:
snip
> $ perl -le 'print 3.4 .3. 4'
> Number found where operator expected at -e line 1, near "3. 4"
> (Missing operator before 4?)
> syntax error at -e line 1, near "3. 4"
> Execution of -e aborted due to compilation errors.
>
On Jan 22, 2008 7:43 PM, Vahid Moghaddasi <[EMAIL PROTECTED]> wrote:
> # egrep "^bin:|^adm:|^daemon:|^root:|^rpm:" /etc/passwd
> root:x:0:0:Linux root:/root:/bin/bash
> bin:x:1:1:Linux bin:/bin:/sbin/nologin
> daemon:x:2:2:Linux daemon:/sbin:/sbin/nologin
> rpm:x:37:37:Linux :/var/lib/rpm:/sbin/no
On Jan 22, 2008 9:31 PM, Chas. Owens <[EMAIL PROTECTED]> wrote:
>
> Off hand I think that would only happen if the user name or the uid
> was the same for some of your users. Can you present a cleaned up
> version of your data the exhibits the problem? Also, You might want
> to rewrite your loop
-Original Message-
>From: Jenda Krynicky <[EMAIL PROTECTED]>
>Sent: Jan 23, 2008 12:59 AM
>To: beginners-list
>Subject: Re: about the dot
>
>From: Jeff Pang <[EMAIL PROTECTED]>
>> I'm a little confused by perl's dot operator.for example,
>>
>> $ perl -le 'print 3 . 4 '
>> 34
>> $ perl -
On Jan 22, 2008 9:24 PM, Tom Phoenix <[EMAIL PROTECTED]> wrote:
> On Jan 22, 2008 5:49 PM, Vahid Moghaddasi <[EMAIL PROTECTED]> wrote:
>
> > I have the following
> > subroutine to sort unique a UNIX password file based on UID and
> > username.
>
> Doesn't your password file already have unique use
On Jan 22, 2008 9:33 PM, Rob Dixon <[EMAIL PROTECTED]> wrote:
snip
> > If the code works (and it isn't guarenteed to)
>
> I'm not sure what you mean here. It's as guaranteed to work as any other
> Perl code snippet I've seen.
snip
I mean that the following is an error.
my $foo = 5;
my @array = @{
Chas. Owens wrote:
>
On Jan 22, 2008 8:45 PM, bootleg86 bootleg86 <[EMAIL PROTECTED]> wrote:
I came across this construct
foreach $i ( @{$y} ) {
#do something
}
Is @ referring to some default array that doesn't need to be declared?
Also it's using the associative version of an array?
I alwa
Vahid Moghaddasi wrote:
Hi,
Hello,
I have a very strange problem (to me anyways). I have the following
subroutine to sort unique a UNIX password file based on UID and
username. But the problem is that some of the users get disappeared
the output password file. I couldn't figure out the patte
On Jan 22, 2008 8:49 PM, Vahid Moghaddasi <[EMAIL PROTECTED]> wrote:
> Hi,
> I have a very strange problem (to me anyways). I have the following
> subroutine to sort unique a UNIX password file based on UID and
> username. But the problem is that some of the users get disappeared
> the output pass
On Jan 22, 2008 5:49 PM, Vahid Moghaddasi <[EMAIL PROTECTED]> wrote:
> I have the following
> subroutine to sort unique a UNIX password file based on UID and
> username.
Doesn't your password file already have unique usernames and unique UIDs?
> But the problem is that some of the users get dis
On Jan 22, 2008 8:45 PM, bootleg86 bootleg86 <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I came across this construct
> foreach $i ( @{$y} ) {
> #do something
> }
>
> Is @ referring to some default array that doesn't need to be declared?
>
> Also it's using the associative version of an array?
> I alway
bootleg86 bootleg86 wrote:
Hi,
Hello,
I came across this construct
foreach $i ( @{$y} ) {
#do something
}
Is @ referring to some default array that doesn't need to be declared?
Also it's using the associative version of an array?
I always thought only hashes were associative.
$y is a re
Jenda Krynicky wrote:
From: "John W. Krahn" <[EMAIL PROTECTED]>
Chas. Owens wrote:
On Jan 22, 2008 10:42 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
I have a perl module that extensively uses a variable named "$main", which
is apparently bound to the script that calls the library.
I can't fi
On Jan 22, 2008 8:25 PM, Jenda Krynicky <[EMAIL PROTECTED]> wrote:
snip
> > Or variables like $main'foo.
>
> I don't think I've ever seen this outside Obfu(scation) or golf.
> It's good to know something like that is possible, but please don't
> use that. Unless of course you do want to confuse som
Hi,
I have a very strange problem (to me anyways). I have the following
subroutine to sort unique a UNIX password file based on UID and
username. But the problem is that some of the users get disappeared
the output password file. I couldn't figure out the pattern of user
disappearance but always t
Hi,
I came across this construct
foreach $i ( @{$y} ) {
#do something
}
Is @ referring to some default array that doesn't need to be declared?
Also it's using the associative version of an array?
I always thought only hashes were associative.
Thanks
--
To unsubscribe, e-mail: [EMAIL PROTECT
From: "John W. Krahn" <[EMAIL PROTECTED]>
> Chas. Owens wrote:
> > On Jan 22, 2008 10:42 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
> >> I have a perl module that extensively uses a variable named "$main", which
> >> is apparently bound to the script that calls the library.
> >>
> >> I can't find
Gunnar Hjalmarsson wrote:
yitzle wrote:
[EMAIL PROTECTED] wrote:
I am trying to redirect to a website:
print $query->redirect(-location=>test.cgi?ID=$value", -
method=>'GET');
Unfortunately the $value never gets passed and I end up with test.cgi?
ID= .
Why do you only have one double-quote
On Tue, Jan 22, 2008 at 05:52:35PM -0500, Chas. Owens wrote:
> On Jan 22, 2008 2:58 PM, lerameur <[EMAIL PROTECTED]> wrote:
> > Hello,
> >
> > I wrote a short perl script (65 lines), simply to count some log file
> > time, and take the average. The script takes 4 minutes to run and go
> > through a
yitzle wrote:
[EMAIL PROTECTED] wrote:
I am trying to redirect to a website:
print $query->redirect(-location=>test.cgi?ID=$value", -
method=>'GET');
Unfortunately the $value never gets passed and I end up with test.cgi?
ID= .
Why do you only have one double-quote on that line?
Are you usin
lerameur wrote:
Hello,
Hello,
I wrote a short perl script (65 lines), simply to count some log file
time, and take the average. The script takes 4 minutes to run and go
through about 8 millions lines.
I would like to know if I can make it run faster. Why?, if I use the
command 'wc -l filena
Why do you only have one double-quote on that line?
Are you using strict and warnings?
print $query->redirect(-location=> "test.cgi?ID=$value", -method=>"GET");
On Jan 22, 2008 4:31 PM, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hi,
> Hopefully this appropriate question for this group. I am
On Jan 22, 2008 2:58 PM, lerameur <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I wrote a short perl script (65 lines), simply to count some log file
> time, and take the average. The script takes 4 minutes to run and go
> through about 8 millions lines.
> I would like to know if I can make it run faster
Hello,
I wrote a short perl script (65 lines), simply to count some log file
time, and take the average. The script takes 4 minutes to run and go
through about 8 millions lines.
I would like to know if I can make it run faster. Why?, if I use the
command 'wc -l filename' , I get the number of li
Hi,
Hopefully this appropriate question for this group. I am trying to
redirect to a website:
print $query->redirect(-location=>test.cgi?ID=$value", -
method=>'GET');
Unfortunately the $value never gets passed and I end up with test.cgi?
ID= .
Thanks,
J
--
To unsubscribe, e-mail: [EMAIL PRO
Chas. Owens wrote:
On Jan 22, 2008 10:42 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
I have a perl module that extensively uses a variable named "$main", which
is apparently bound to the script that calls the library.
I can't find where the exact semantics of this automagic variable defined.
Chas. Owens wrote:
On Jan 21, 2008 4:30 PM, Kevin Viel <[EMAIL PROTECTED]> wrote:
snip
You placed another little gem in here for me to digest:
$outer{$snp}{$_}++ for $genotype =~ /(.)/g; }
I guess when I conceive of that by myself, I should move to the intermediate
mailing list :)
snip
On Tuesday 22 January 2008 13:06:58 Paul Lalli wrote:
> On Jan 22, 2:00 am, [EMAIL PROTECTED] (Jeff Pang) wrote:
> > I'm a little confused by perl's dot operator.for example,
> >
> > $ perl -le 'print 3 . 4 '
> > 34
> > $ perl -le 'print 3.4 '
> > 3.4
> >
> > these two commands got different resu
On Jan 22, 2:00 am, [EMAIL PROTECTED] (Jeff Pang) wrote:
> I'm a little confused by perl's dot operator.for example,
>
> $ perl -le 'print 3 . 4 '
> 34
> $ perl -le 'print 3.4 '
> 3.4
>
> these two commands got different results.
>
> who says Perl interpreter will ignore the blackspace around an
From: Jeff Pang <[EMAIL PROTECTED]>
> I'm a little confused by perl's dot operator.for example,
>
> $ perl -le 'print 3 . 4 '
> 34
> $ perl -le 'print 3.4 '
> 3.4
>
> these two commands got different results.
>
> who says Perl interpreter will ignore the blackspace around an operator? I
> sa
On Jan 21, 2008 4:30 PM, Kevin Viel <[EMAIL PROTECTED]> wrote:
snip
> You placed another little gem in here for me to digest:
>
> > $outer{$snp}{$_}++ for $genotype =~ /(.)/g; }
>
> I guess when I conceive of that by myself, I should move to the intermediate
> mailing list :)
snip
It could a
On Jan 22, 2008 10:42 AM, Jonathan Mast <[EMAIL PROTECTED]> wrote:
> I have a perl module that extensively uses a variable named "$main", which
> is apparently bound to the script that calls the library.
>
> I can't find where the exact semantics of this automagic variable defined.
snip
There is n
I have a perl module that extensively uses a variable named "$main", which
is apparently bound to the script that calls the library.
I can't find where the exact semantics of this automagic variable defined.
thanks,
jhmast
> -Original Message-
> From: Chas. Owens [mailto:[EMAIL PROTECTED]
> Sent: Monday, January 21, 2008 1:11 PM
> To: Kevin Viel
> Cc: beginners@perl.org
> Subject: Re: Hash of hashes?
> #! /usr/bin/perl
>
> use strict;
> use warnings;
>
> use Data::Dumper;
>
> #this needs a better more
Zhao, Bingfeng wrote:
Hi list,
I'm in trouble and hope who can work me out.
I want to so some replacements, so I want to keep all replacement
policies in a hash so that I can use them in a foreach loop, such as:
my %policies = (
"abc" => "def",
"jfk\s+" => "jfk ",
"(\d+)u
Zhao, Bingfeng wrote:
Hi list,
Hello,
I'm in trouble and hope who can work me out.
I want to so some replacements, so I want to keep all replacement
policies in a hash so that I can use them in a foreach loop, such as:
my %policies = (
"abc" => "def",
"jfk\s+" => "jfk ",
Jeff Pang wrote:
>
I'm a little confused by perl's dot operator.for example,
$ perl -le 'print 3 . 4 ' 34 $ perl -le 'print 3.4 ' 3.4
these two commands got different results.
who says Perl interpreter will ignore the blackspace around an
operator? I saw it doesn't here. Ok you may say 3.4 is
On Jan 19, 3:20 pm, [EMAIL PROTECTED] (Daniel D Jones) wrote:
> I'm running Gentoo, which does not yet have version 5.10 in the tree. I
> downloaded and installed version 5.10 from source. (I'm not certain that
> this is the cause of the issue, but it's the only thing I can think of.)
> Now, Perl
Thanks, Jeff. But for qr/(\d+)uu/ and 'uu\1' on '22uu', I got 'uu\1' instead of
'uu22'.
-Original Message-
From: Jeff Pang [mailto:[EMAIL PROTECTED]
Sent: Tuesday, January 22, 2008 5:02 PM
To: beginners-list
Subject: Re: list or hash of replacement regex
-Original Message-
>
-Original Message-
>From: "Zhao, Bingfeng" <[EMAIL PROTECTED]>
>Sent: Jan 22, 2008 4:53 PM
>To: beginners@perl.org
>Subject: list or hash of replacement regex
>
>But perl complains, so I update it as:
>my %policies = (
> qr/abc/ => "def",
> qr/jfk\s+/ => "jfk ",
> qr/\d+
Hi list,
I'm in trouble and hope who can work me out.
I want to so some replacements, so I want to keep all replacement
policies in a hash so that I can use them in a foreach loop, such as:
my %policies = (
"abc" => "def",
"jfk\s+" => "jfk ",
"(\d+)uu" => "uu\1"
#... many p
42 matches
Mail list logo