Efficiency of code
Posted: Thu Oct 21, 2021 7:15 pm
Hello,
as a complete newbie I have put together my first script (thx to Mathew), which is about 300 lines long and now I would like to modify it so that it compiles as efficiently as possible. So my question is what is better/more efficient (thus also faster when changing the user inputs):
OR
???
Or is there any difference?
as a complete newbie I have put together my first script (thx to Mathew), which is about 300 lines long and now I would like to modify it so that it compiles as efficiently as possible. So my question is what is better/more efficient (thus also faster when changing the user inputs):
Code: Select all
trendLong= emaFast > emaSlow
trendShort = emaSlow > emaFast
Code: Select all
trend = na
if emaFast > emaSlow
trend := "Long"
else if emaSlow > emaFast
trend := "Short"
Or is there any difference?