in reply to Returning Values from Subroutines

You're close:
sub main{ my $answer = &add(1,2); print $answer; } sub add{ my $value1 = shift; my $value2 = shift; my $result = ($value1 + $value2); return $result; }

TStanley
--------
It is God's job to forgive Osama Bin Laden. It is our job to arrange the meeting -- General Norman Schwartzkopf