in reply to Re^2: Passing value to a Perl module
in thread Passing value to a Perl module

Indeed. Your module says:

my $hello = hello(); sub hello { my $h = shift; return; } print $hello;

So $hello is given the return value of hello() which is undef. You probably want to return $h instead.

PS. I would strongly advise naming your variables and your subroutines with different names, otherwise it's going to get very confusing very quickly.

PPS. and as stevieb quite rightly says, pass an argument when you call hello().