[32665] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3941 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon May 6 18:09:38 2013

Date: Mon, 6 May 2013 15:09:15 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Mon, 6 May 2013     Volume: 11 Number: 3941

Today's topics:
    Re: Is Perl dying or not? <visphatesjava@gmail.com>
    Re: nice parallel file reading <tzz@lifelogs.com>
        oh perlbal you!!! you got what i need....but you dotn w <visphatesjava@gmail.com>
        printf question <jblack@nospam.com>
    Re: printf question <hjp-usenet3@hjp.at>
    Re: printf question (hymie!)
    Re: printf question <jblack@nospam.com>
    Re: printf question <jblack@nospam.com>
        whats the best perl web framework to make money? <visphatesjava@gmail.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Mon, 6 May 2013 12:12:04 -0700 (PDT)
From: johannes falcone <visphatesjava@gmail.com>
Subject: Re: Is Perl dying or not?
Message-Id: <89e1aa98-4b00-486e-b3c8-dbd161ca963b@googlegroups.com>

On Friday, October 19, 2012 7:43:53 PM UTC-7, Ignoramus7380 wrote:
> Let me first state that I a perl user, since 1996, I have been always
> 
> very happy with perl. I have written 1,430 perl scripts and modules. I
> 
> am self employed and make most of my income from websites that I wrote
> 
> using mod_perl.
> 
> 
> 
> So this is not some kind of "perl suxxx" troll. Rather, I want to ask
> 
> if perl will continue to be a viable ecosystem. I have a lot invested
> 
> in and relying on perl and I have a vested interest in having perl to
> 
> be a great platform.
> 
> 
> 
> Lately, I have been seeing a lot of evidence that adoption and use
> 
> of perl declines in favor of superficially "easier" languages. The
> 
> number of developers, commits, activity etc seems to be dropping. Even
> 
> this newsgroup seems to be declining faster than Usenet in general. 
> 
> 
> 
> My question is, should I be concerned by this trend or not?
> 
> Ultimately, I do not care super that much that perl is number one
> 
> scripting language, only that it continues to be a great platform. 
> 
> 
> 
> Thanks
> 
> 
> 
> i

well I see dancer, catalyst, mojolicious, memcached, mogilesFS, perlbal, plack, starman, continuity, perl 5.16.3 and s megashitload of stuff on metacpan so I think perl is far from dead

"just like java, but on time and under budget"

lolz


------------------------------

Date: Mon, 06 May 2013 01:08:18 -0400
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: nice parallel file reading
Message-Id: <87d2t4d7b1.fsf@lifelogs.com>

On Sat, 27 Apr 2013 07:49:40 -0700 Jürgen Exner <jurgenex@hotmail.com> wrote: 

JE> While this might be mildly interesting as an academic exercise I wonder
JE> if there is any actual non-contrived application where you would have to
JE> read multiple files synchronously line-by-line and at the same time the
JE> files are too large to just load them into a variable and then process
JE> their content.

I've had to do this.  I had multiple log files being simultaneously
processed by log processors and aggregators for real-time monitoring.

(Each log processor was reading simultaneously from multiple files.)

The individual files got into the gigabytes and were frequently
rotated.

This worked pretty well, keeping up with significant amounts of traffic,
and never thrashing or ballooning memory usage.  Perl 5.12.

Ted


------------------------------

Date: Mon, 6 May 2013 11:44:46 -0700 (PDT)
From: johannes falcone <visphatesjava@gmail.com>
Subject: oh perlbal you!!! you got what i need....but you dotn work with 5 16
Message-Id: <93eb01f2-74b0-43e7-ad48-0b010efa6eac@googlegroups.com>

dont work with 5.16.3

oh perbal uuuuuuuu 


------------------------------

Date: Mon, 6 May 2013 14:51:25 -0500
From: John Black <jblack@nospam.com>
Subject: printf question
Message-Id: <MPG.2bf1c5bc4b0961a6989773@news.eternal-september.org>

Hopefully a simple question...

Given this printf that specifies some fixed length left justified columns:

   printf "%-30s, %-30s, %-30s\n", $a, $b, $c;

How can I make the hardcoded number 30 use a variable, say $len instead?

This does not work:

   printf "%-$lens, %-$lens, %-lens\n", $a, $b, $c;

I'm guessing because perl would have trouble knowing that the s at the end is not part of the 
variable?  Thanks.

John Black


------------------------------

Date: Mon, 6 May 2013 22:08:20 +0200
From: "Peter J. Holzer" <hjp-usenet3@hjp.at>
Subject: Re: printf question
Message-Id: <slrnkog3dk.sr6.hjp-usenet3@hrunkner.hjp.at>

On 2013-05-06 19:51, John Black <jblack@nospam.com> wrote:
> Hopefully a simple question...
>
> Given this printf that specifies some fixed length left justified columns:
>
>    printf "%-30s, %-30s, %-30s\n", $a, $b, $c;
>
> How can I make the hardcoded number 30 use a variable, say $len instead?
>
> This does not work:
>
>    printf "%-$lens, %-$lens, %-lens\n", $a, $b, $c;
>
> I'm guessing because perl would have trouble knowing that the s at the
> end is not part of the variable?

Yes.

Either:

   printf "%-${len}s, %-${len}s, %-${len}s\n", $a, $b, $c;

Or (more C-like):

   printf "%-*s, %-*s, %-*s\n", $len, $a, $len, $b, $len, $c;

	hp


-- 
   _  | Peter J. Holzer    | Fluch der elektronischen Textverarbeitung:
|_|_) | Sysadmin WSR       | Man feilt solange an seinen Text um, bis
| |   | hjp@hjp.at         | die Satzbestandteile des Satzes nicht mehr
__/   | http://www.hjp.at/ | zusammenpaßt. -- Ralph Babel


------------------------------

Date: 06 May 2013 20:10:40 GMT
From: hymie@lactose.homelinux.net (hymie!)
Subject: Re: printf question
Message-Id: <51880e40$0$36530$862e30e2@ngroups.net>

In our last episode, the evil Dr. Lacto had captured our hero,
  John Black <jblack@nospam.com>, who said:
>Hopefully a simple question...
>
>Given this printf that specifies some fixed length left justified columns:
>
>   printf "%-30s, %-30s, %-30s\n", $a, $b, $c;
>
>How can I make the hardcoded number 30 use a variable, say $len instead?

$format = "%-${len}s, %-${len}s, %-${len}s\n";
printf $format, $a, $b, $c;

--hymie!    http://lactose.homelinux.net/~hymie    hymie@lactose.homelinux.net
-------------------------------------------------------------------------------


------------------------------

Date: Mon, 6 May 2013 17:06:23 -0500
From: John Black <jblack@nospam.com>
Subject: Re: printf question
Message-Id: <MPG.2bf1e55668192d2e989774@news.eternal-september.org>

In article <slrnkog3dk.sr6.hjp-usenet3@hrunkner.hjp.at>, hjp-usenet3@hjp.at says...
> 
> On 2013-05-06 19:51, John Black <jblack@nospam.com> wrote:
> > Hopefully a simple question...
> >
> > Given this printf that specifies some fixed length left justified columns:
> >
> >    printf "%-30s, %-30s, %-30s\n", $a, $b, $c;
> >
> > How can I make the hardcoded number 30 use a variable, say $len instead?
> >
> > This does not work:
> >
> >    printf "%-$lens, %-$lens, %-lens\n", $a, $b, $c;
> >
> > I'm guessing because perl would have trouble knowing that the s at the
> > end is not part of the variable?
> 
> Yes.
> 
> Either:
> 
>    printf "%-${len}s, %-${len}s, %-${len}s\n", $a, $b, $c;
> 
> Or (more C-like):
> 
>    printf "%-*s, %-*s, %-*s\n", $len, $a, $len, $b, $len, $c;
> 
> 	hp

Thanks much.  I guess with Perl, its probably going to be adding either {}, [] or ().

John Black


------------------------------

Date: Mon, 6 May 2013 17:07:24 -0500
From: John Black <jblack@nospam.com>
Subject: Re: printf question
Message-Id: <MPG.2bf1e599c9fe4888989775@news.eternal-september.org>

In article <51880e40$0$36530$862e30e2@ngroups.net>, hymie@lactose.homelinux.net says...
> 
> In our last episode, the evil Dr. Lacto had captured our hero,
>   John Black <jblack@nospam.com>, who said:
> >Hopefully a simple question...
> >
> >Given this printf that specifies some fixed length left justified columns:
> >
> >   printf "%-30s, %-30s, %-30s\n", $a, $b, $c;
> >
> >How can I make the hardcoded number 30 use a variable, say $len instead?
> 
> $format = "%-${len}s, %-${len}s, %-${len}s\n";
> printf $format, $a, $b, $c;

I like the idea of putting $format in its own variable for readability and for use in 
multiple printf statements.  Thanks.

John Black


------------------------------

Date: Mon, 6 May 2013 11:48:12 -0700 (PDT)
From: johannes falcone <visphatesjava@gmail.com>
Subject: whats the best perl web framework to make money?
Message-Id: <3854e7cd-4427-493e-98a9-3b37ba3a00a5@googlegroups.com>

I am poor and wana get rich through the web.


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

Back issues are available via anonymous ftp from
ftp://cil-www.oce.orst.edu/pub/perl/old-digests. 

#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V11 Issue 3941
***************************************


home help back first fref pref prev next nref lref last post