tobold.org

correct • elegant • free

△ comp.lang.perl △

◅ command not found

Need help on sockets ▻

Perl one liner challenge

In article <5aa959$67l@cdn_news.telecom.com.au>,
Steven Lee <c822535@vuh263.telecom.com.au> wrote:
>Is it possible to make this script into a one liner?

You can easily do it in two.

    #! /usr/local/bin/perl -n
    BEGIN { $| = 1 } map { print; select undef, undef, undef, 0.01 } split //;

Tim.
--
Tim Goodwin   | "A language needs both intestines and guts." -- Larry Wall

Original headers:

From: tim@pipex.net (Tim Goodwin)
Newsgroups: comp.lang.perl.misc
Subject: Re: Perl one liner challenge
Date: 7 Jan 1997 13:07:46 GMT
Organization: UUNET PIPEX
Message-ID: <5athr2$qo@wave.news.pipex.net>
References: <5aa959$67l@cdn_news.telecom.com.au>

△ comp.lang.perl △

◅ command not found

Need help on sockets ▻