#!/usr/bin/perl

use Coro;
use Coro::Event;
use Coro::LWP; # should be use'd as early as possible
use LWP::Simple;

$SIG{PIPE} = 'IGNORE';

my @pids;

push @pid, async {
   print "starting to fetch http://www.google.de/\n";
   get "http://www.google.de/";
   print "fetched http://www.google.de/\n";
};

push @pid, async {
   print "starting to fetch http://www.yahoo.com/\n";
   get "http://www.yahoo.com/";
   print "fetched http://www.yahoo.com/\n";
};

$_->join for @pid;



syntax highlighted by Code2HTML, v. 0.9.1