in reply to calling a subroutine from another subroutine

abcdefg:

The first problem is that you're using the assignment operator as a string comparison operator. So the first comparison in your first subroutine is *always* true, making the subroutine return "01". Instead of "=", use "eq", the string comparison operator....

...roboticus

When your only tool is a hammer, all problems look like your thumb.

  • Comment on Re: calling a subroutine from another subroutine