if holding=0 and 開倉 then begin
buy(1,1,LIMITR,c);
end
和
if 開倉 then begin
buy(holding=0,1,LIMITR,c);
end
有區(qū)別嗎? 區(qū)別在哪?
在什么樣的情況下效果會不一樣呢?
在有全局變量賦值上,會不一樣
比如:
variable:n=0;
if holding=0 and 開倉 then begin
buy(1,1,LIMITR,c);
n:=n+1;
end
和
if 開倉 then begin
buy(holding=0,1,LIMITR,c);
n:=n+1;
end
這兩個會不一樣,缺少個holding=0 的判斷,得出的N結果會不一樣
[此貼子已經被作者于2013/12/20 8:50:51編輯過]