You are calling verNum2 without any parameters, like this:
var num = verNum2();
And because you called it without a parameter it has nothing to assign to num:
function verNum2(result) {
var num = result;
alert("num: "+num);
return num;
}
Num
is what you return and that is then unassigned because
result
was when calling it.
Good luck!