Hi Pakema
It's not really clear what you are trying to achieve here, but I have given you a basic solution to what I think you are trying to achieve below. It could be simplified further, but I don't want to lose you if you're just starting out!!
Basically each sub (F1, F2 and F3) will need to be executed separately, each will pass their a and b values to F4, which will determine whether they are equal and display a suitable message. The solution could easily be configured such that F4 is a function and returns a true or false value to each of the calling subs, which would then be able to deal with the result in their own way. It could be further simplified whereby only one sub is required and it could simply loop through a specified number of iterations, each time passing different values to F4, but without knowing what you are trying to achieve, I've kept it to the same basic format that you gave.
If you need further assistance, perhaps you could give us more specific details of exactly what it is you are trying to achieve.
sub F1
dim a
dim b
a = 5
b = 6
call F4(a, b)
end sub
sub F2
dim a
dim b
a = 3
b = 0
call F4(a, b)
end sub
function F3
dim a
dim b
a = 4
b = 7
call F4(a, b)
end function
sub F4(a, b)
if a = b then
log.message("A and B are the same")
else
Log.error("A must be B!")
end if
end sub
Regards
Stephen.