in reply to sub returning undef
mysub2(mysub1());
mysub1() will return undef. The problem is, when you pass undef directly to mysub2(...), @_ becomes an array of length 1, with the first (and only) element begin undef. Instead, try this:defined mysub1() ? "Exists" : "Array is not defined";
|
|---|