very basic #define question
You know that double f(double x) {return x*x; } or using MQL's MathPow(base, power) does the job.
Although good programming skills are required for making good EAs, I woud think that the focus here is not programming style, but research and implementing strategies to make profit.
The problem is that I have several nested function calls that are slowing down the EA @ runtime. I would like to solve this @ compile-time, by using the pre-processor. Otherwise I have to maintain several different EAs with cut&pasted code, which leads to a mess when I make bug-fixes :)
stupid question, how do I do the following in MQL4?
#define f(x) x^2
if I can't do this, can I create a function pointer? It seems that function calls are very expensive with the MQL4 compiler