# Like this my $multilineString = readpipe('extprog'); # or split on current $/ my @lines = readpipe('extprog')