#!/usr/bin/perl
# w3.12.pl  Subroutine example.  Repeating the refrain.

print "Where Have All the Flowers Gone\n\n";

sub refrain() {
    print "   When will they ever learn\n";
    print "   When will they ever learn\n\n";
}

print <<EOT;
Where have all the flowers gone
Long time passing
Where have all the flowers gone
Long time ago
Where have all the flowers gone
Young girls picked them everyone

EOT

&refrain();


print <<EOT;
Where have all the young girls gone
Long time passing
Where have all the young girls gone
Long time ago
Where have all the young girls gone
Gone to young men everyone

EOT

&refrain();

print <<EOT;
Where have all the young men gone
Long time passing
Where have all the young men gone
Long time ago
Where have all the young men gone
Gone to soldiers everyone

EOT

&refrain();
               
print <<EOT;
Where have all the soldiers gone
Long time passing
Where have all the soldiers gone
Long time ago
Where have all the soldiers gone
Gone to graveyards everyone

EOT

&refrain();
            
print <<EOT;
Where have all the graveyards gone
Long time passing
Where have all the graveyards gone
Long time ago
Where have all the graveyards gone
Gone to flowers everyone

EOT

&refrain();   
