#!perl main(); sub main { my @output; push (@output, "Here is something to print out\n", "Here is yet another line\n"); extra(\@output); print @output; } sub extra { my $resRef = shift; push (@$resRef, "Here is an extra line\n"); } exit 0;