in reply to print subroutine name calls subroutine but with appended 1 number to the output

As stated by others the 1 shows that the subroutine does its job and return even when return was not stated explicitly, for all it worth, it should also be noted that subroutine should also be called with parentheses like this:

foo();
even when no parameter is been passed.
Reason ( Imagine this: calling the subroutine before it's decleared):
foo; ## Oops sub foo { print "hello"; } print "\n";
but with
foo(); # it works

Replies are listed 'Best First'.
Re^2: print subroutine name calls subroutine but with appended 1 number to the output
by Anonymous Monk on May 02, 2012 at 05:32 UTC

    Thank you everyone!