[25969] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 8188 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Jun 20 09:05:33 2005

Date: Mon, 20 Jun 2005 06:05:08 -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, 20 Jun 2005     Volume: 10 Number: 8188

Today's topics:
         Re: Q for the old-timers: antecedents to the ST? <ron@savage.net.au>
        concatenating strings or sprintf? <jens.luedicke@gmail.com>
    Re: concatenating strings or sprintf? <tintin@invalid.invalid>
    Re: concatenating strings or sprintf? <sherm@dot-app.org>
    Re: concatenating strings or sprintf? <kevin@vaildc.net>
    Re: How to kill a forked child process... <moritz.karbach@desy.de>
    Re: How to kill a forked child process... <moritz.karbach@desy.de>
    Re: Q for the old-timers: antecedents to the ST? <dha@panix.com>
    Re: Q for the old-timers: antecedents to the ST? <abigail@abigail.nl>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: Mon, 20 Jun 2005 20:00:35 +1000
From:     Ron Savage <ron@savage.net.au>
Subject:  Re: Q for the old-timers: antecedents to the ST?
Message-Id: <200562020035.916307@ron>

On Mon, 20 Jun 2005 04:47:03 +1000, kj wrote:

Hi kj

> technique.  After all, there is a very similar technique, which
> I've seen referred to as "tag shuffling", for randomly shuffling a
> list.  In Perl it would be rendered like this:

It used to be called a 'tag sort', from the time when computer memory was=
 tiny.

The algorithm was:
o Stockpile the key and the disk address for each record
o Sort the keys, dragging around the disk address with each key. This disk 
address is no more than a (C-style) pointer to the data
o Retrieve the keys in sorted order, and with each key, get the disk address=
 and 
from that the original record. So, you only need 1 record in memory at a=
 time
o Write the records in sorted order

It's quite theoretical compared to most things students had to learn back=
 then, 
and I can assure you getting the concept across was a painful process.

When I say theoretical, I don't mean difficult, but rather just that it=
 required 
a visualization manoeuvre students had simply never encountered before.





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

Date: Mon, 20 Jun 2005 12:23:11 +0200
From: Jens Luedicke <jens.luedicke@gmail.com>
Subject: concatenating strings or sprintf?
Message-Id: <42b698ff$0$27789$9b4e6d93@newsread2.arcor-online.net>

-----BEGIN xxx SIGNED MESSAGE-----
Hash: SHA1

Hiya..

I have a stupid question, what is more efficient to glue strings
together? using the . operator or sprintf()?

- --
Jens Luedicke
web: http://perldude.de

-----BEGIN xxx SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCtpkPiCvkc4H0gTERAvsEAJ9Z3rQfPAeA2Pqc7xFN2EHcixaW0gCg5ueK
75CwEDWli1+pj/cDRZiTvUM=
=AZL1
-----END PGP SIGNATURE-----


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

Date: Mon, 20 Jun 2005 22:54:45 +1200
From: "Tintin" <tintin@invalid.invalid>
Subject: Re: concatenating strings or sprintf?
Message-Id: <Ufxte.8729$U4.1185702@news.xtra.co.nz>


"Jens Luedicke" <jens.luedicke@gmail.com> wrote in message 
news:42b698ff$0$27789$9b4e6d93@newsread2.arcor-online.net...
> I have a stupid question, what is more efficient to glue strings
> together? using the . operator or sprintf()?

Why use either?

my $string1='foo';
my $string2='bar';

my $concat="$string1$string2";




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

Date: Mon, 20 Jun 2005 06:03:24 -0400
From: Sherm Pendley <sherm@dot-app.org>
Subject: Re: concatenating strings or sprintf?
Message-Id: <87r7ex4a6r.fsf@dot-app.org>

Jens Luedicke <jens.luedicke@gmail.com> writes:

> I have a stupid question, what is more efficient to glue strings
> together? using the . operator or sprintf()?

I don't know, but the Benchmark module would be useful for finding out. I
wouldn't expect the difference to be all that significant without a few
bajillion iterations.

sherm--


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

Date: Mon, 20 Jun 2005 11:39:31 GMT
From: Kevin Michael Vail <kevin@vaildc.net>
Subject: Re: concatenating strings or sprintf?
Message-Id: <kevin-C6A3BD.07393120062005@news.verizon.net>

In article <Ufxte.8729$U4.1185702@news.xtra.co.nz>,
 "Tintin" <tintin@invalid.invalid> wrote:

> "Jens Luedicke" <jens.luedicke@gmail.com> wrote in message 
> news:42b698ff$0$27789$9b4e6d93@newsread2.arcor-online.net...
> > I have a stupid question, what is more efficient to glue strings
> > together? using the . operator or sprintf()?
> 
> Why use either?
> 
> my $string1='foo';
> my $string2='bar';
> 
> my $concat="$string1$string2";

I think this is the same internally as:

$string1 . $string2
-- 
Kevin Michael Vail | a billion stars go spinning through the night,
kevin@vaildc.net   | blazing high above your head.
 . . . . . . . . . | But _in_ you is the presence that
  . . . . . . . .  | will be, when all the stars are dead. 
 . . . . . . . . . |     (Rainer Maria Rilke)


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

Date: Fri, 17 Jun 2005 19:13:25 +0200
From: Moritz Karbach <moritz.karbach@desy.de>
Subject: Re: How to kill a forked child process...
Message-Id: <d960g7$512e7$1@claire.desy.de>

> The parent process of the child (not the sibling) must wait() or ignore
> $SIG{CHLD}.

Thanks for the hint. I moved the 

        $SIG{CHLD} = "IGNORE";
        $SIG{CLD} = "IGNORE";

to the parent and the zombies disappeared.

> This doesn't really have anything to do with Perl, this is a Unix
> question.

I'm sorry. Since both Perl and Unix signal handling are relatively new to
me, it's hard for me to distinguish.

Cheers,

- Moritz


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

Date: Mon, 20 Jun 2005 11:08:22 +0200
From: Moritz Karbach <moritz.karbach@desy.de>
Subject: Re: How to kill a forked child process...
Message-Id: <d96127$514v0$1@claire.desy.de>

Sorry for the multiple postings, got problems with IT...

- Moritz



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

Date: Mon, 20 Jun 2005 06:29:11 +0000 (UTC)
From: "David H. Adler" <dha@panix.com>
Subject: Re: Q for the old-timers: antecedents to the ST?
Message-Id: <slrndbcohn.9ts.dha@panix2.panix.com>

On 2005-06-19, Tad McClellan <tadmc@augustmail.com> wrote:
> Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> wrote:
>
>
>> So whoever it was,
>
>
> Tom Christiansen, I'm pretty sure.
>
>
>> half-jokingly called it "Schwartz Transform" and the name stuck.

Yes, it was Tom. If memory serves, he didn't mean the eponymy as a
compliment... :-)

dha
-- 
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
"Well, to make this story the way it should be done we will
[need] technology that won't invented for 30 years and a budget that
could pay for a large south american country." "What have we got?" "25
cents and a block of wood." - Possible Dr. Who budget conference


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

Date: 20 Jun 2005 07:32:06 GMT
From: Abigail <abigail@abigail.nl>
Subject: Re: Q for the old-timers: antecedents to the ST?
Message-Id: <slrndbcs7l.14f.abigail@alexandra.abigail.nl>

David H. Adler (dha@panix.com) wrote on MMMMCCCXI September MCMXCIII in
<URL:news:slrndbcohn.9ts.dha@panix2.panix.com>:
==  On 2005-06-19, Tad McClellan <tadmc@augustmail.com> wrote:
== > Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> wrote:
== >
== >
== >> So whoever it was,
== >
== >
== > Tom Christiansen, I'm pretty sure.
== >
== >
== >> half-jokingly called it "Schwartz Transform" and the name stuck.
==  
==  Yes, it was Tom. If memory serves, he didn't mean the eponymy as a
==  compliment... :-)


Indeed.


Abigail
-- 
#!/opt/perl/bin/perl -w
$\ = $"; $SIG {TERM} = sub {print and exit};
kill 15 => fork for qw /Just another Perl Hacker/;


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

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:

#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc.  For subscription or unsubscription requests, send
#the single line:
#
#	subscribe perl-users
#or:
#	unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.  

NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

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

#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.

#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 V10 Issue 8188
***************************************


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