in reply to Return value in ternary
print "$return_value\n"; [download]
On a side note, use strict and warnings, and clean up the warnings you get:
sub test { [download]