lingo为什么总报错“;”没找到逻辑操作符?
model:sets:number/1..26/:n,m,x;endsets@for(number(i):@sum(number(j)|j#le#i:n(j))#eq#@...
model:
sets:
number/1..26/:n,m,x;
endsets
@for(number(i):
@sum(number(j)|j#le#i:
n(j))#eq#@floor((i+1)/2);
@sum(number(j)|j#le#i:
m(j))#eq#i);
end
s= @sum(number(i)|i#le#26:x(i)*(30.63*n(i)+350.1+90.72*m(i));
s<=5000;
max=@sum((x(i)*(18.8*n(i)+223.12+66*m(i)|i#le#26)/5000);
第七行后面那个;我纯粹刚开始学的新人啊,各位大佬帮忙QAQ 展开
sets:
number/1..26/:n,m,x;
endsets
@for(number(i):
@sum(number(j)|j#le#i:
n(j))#eq#@floor((i+1)/2);
@sum(number(j)|j#le#i:
m(j))#eq#i);
end
s= @sum(number(i)|i#le#26:x(i)*(30.63*n(i)+350.1+90.72*m(i));
s<=5000;
max=@sum((x(i)*(18.8*n(i)+223.12+66*m(i)|i#le#26)/5000);
第七行后面那个;我纯粹刚开始学的新人啊,各位大佬帮忙QAQ 展开
1个回答
展开全部
model:
sets:
number/1..26/:n,m,x;
endsets
@for(number(i):
@sum(number(j)|j#le#i:
n(j))=@floor((i+1)/2));
@for(number(i):
@sum(number(j)|j#le#i:
m(j))=i);
s= @sum(number(i)|i#le#26:x(i)*(30.63*n(i)+350.1+90.72*m(i)));
s<=5000;
max=@sum(number(i)|i#le#26:x(i)*(18.8*n(i)+223.12+66*m(i))/5000);
sets:
number/1..26/:n,m,x;
endsets
@for(number(i):
@sum(number(j)|j#le#i:
n(j))=@floor((i+1)/2));
@for(number(i):
@sum(number(j)|j#le#i:
m(j))=i);
s= @sum(number(i)|i#le#26:x(i)*(30.63*n(i)+350.1+90.72*m(i)));
s<=5000;
max=@sum(number(i)|i#le#26:x(i)*(18.8*n(i)+223.12+66*m(i))/5000);
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询