is this legal?
my (@par,@whandicap) = &get_par_for_course;
...
sub get_par_for_course {
# --------------------------------------------------------
# lookup course and get par for each hole
&switch_to_courses;
my (%course) = &get_record2('1'); # always berkeley hills = #1
my (@par) = split (/:/, $course{'WPar'});
my (@whandicap) = split (/:/, $course{'WHandicap'});
return(@par,@whandicap);
}
or do i need separate routines to retrieve the two elements?
Code:
... my (@par,@whandicap) = &get_par_for_course;
...
sub get_par_for_course {
# --------------------------------------------------------
# lookup course and get par for each hole
&switch_to_courses;
my (%course) = &get_record2('1'); # always berkeley hills = #1
my (@par) = split (/:/, $course{'WPar'});
my (@whandicap) = split (/:/, $course{'WHandicap'});
return(@par,@whandicap);
}
or do i need separate routines to retrieve the two elements?