I would like to know if there is any way of optimising a powerlanguage code, so that it compiles, executes and optimise faster.
I have heard for example that multiplication is faster than division: * .5 instead of /2 is faster.
I am wondering if the following would be faster as well. Let's say you have 10 conditions. You could write this way:
Code: Select all
condtion1 = close > low;
condition2 = ema >= sma;
.
.
.
condition10 = close[1] > open[1]
if condition1 and condition2 ..... and condition10 then buy etc.
Code: Select all
condition1 = close > low;
if condition1 then
begin
condition2 = ema > sma;
if condition2 then
begin
.
.
.
if condition10 then begin buy etc.
Many thanks,