I know it maybe weird to ask this kind of question, but I am not sure Julia has this kind of way to achieve what I want. Here is one example code:
function initialize(a,b,c)
do something
return x
end
function run(a,b,c)
do something with the output from initialize, x
end
I am wondering that could I just use the return value from initialize() function, but without calling it? The reason I don’t want to call for initialize() is because my initialize() function is very time consuming, and the run() function is within a loop, if I call the initialize() function every time, it would be very time consuming. Any suggestions would be very appreciated.