variable:n1=0,n2=0;
if 平多条件 and 持仓判断 then begin
平多语句;
n1:=n1+c-enterprice;
end
if 平空条件 and 持仓判断 then begin
平空语句;
n2:=n2+enterpirce-c;
end
n1是多仓的累计盈利点数,n2是空仓的累计盈利点数
清零的话还是需要多加一句清零的
<0表示一天下来是亏损的
>0表示一天下来是盈利的
if time>=151500 then begin
n1:=0;
n2:=0;
end