I created a dummy sphere and used the coordinates as global variables. The coordinates can be changed and read from inside the functions. Altough I would prefer to use pointers or a function that returns a value...
make object sphere 1,0,0,0
number#=4
position object sphere 1,number#,0,0
multiplyWithFour()
number#=object position x(1)
print $number
wait key
end
function multiplyWithFour()
number#=object position x(1)
position object 1,number#*4,0,0
endfunction
I haven't tested the code above, but I think you will get the picture