@total_score = 0;
if @status1 == AC; then
@total_score = @total_score + @score1;
fi
if @status2 == AC; then
@total_score = @total_score + @score2;
fi
if @status3 == AC; then
@total_score = @total_score + @score3;
fi
if @status4 == AC; then
@total_score = @total_score + @score4;
fi
if @status5 == AC; then
@total_score = @total_score + @score5
fi
if @status6 == AC; then
@total_score = @total_score + @score6;
fi
if @total_score == 100; then
@final_status = AC;
@total_score = 200;
else
@final_status = UNAC;
fi
@final_time = @time1 + @time2 + @time3 + @time4 + @time5 + @time6;
@final_memory = @memory1 + @memory2 + @memory3 + @memory4 + @memory5 + @memory6;
报错了。错误原因(看不懂):Script Compile Error: Parse error: Unexpected FI, at Offset 379 Position 67, currentNode is assign。
想要实现的效果是如果这道题 AC 了那么就按 200 分算,否则按原来分数算。不用得分倍率的原因是防止暴力得到太高的分数。