var x,y,z:integer;begin
memo1.Lines.clear;
memo1.Lines.Add('Start:');
for X:=1 to 2009 do
for Y:=1 to 2009 do
for Z:=1 to 2009 do
begin
if (X+Y+Z=2092) and (0.2*X+0.5*Y+Z=441.2) then
memo1.Lines.Add(IntTostr(X)+' '+IntTostr(Y)+' '+IntTostr(Z));
end;
memo1.Lines.Add('End');
end;代码如上,无解。
start:
End
memo1.Lines.clear;
memo1.Lines.Add('Start:');
for X:=1 to 2009 do
for Y:=1 to 2009 do
for Z:=1 to 2009 do
begin
if (X+Y+Z=2092) and (0.2*X+0.5*Y+Z=441.2) then
memo1.Lines.Add(IntTostr(X)+' '+IntTostr(Y)+' '+IntTostr(Z));
end;
memo1.Lines.Add('End');
end;代码如上,无解。
start:
End
解决方案 »
- delphi如何查找网页中指定的内容?
- 为啥我的模拟按钮单击没有反应??
- 如何将一张表中的image字段值传到另一张表的image字段中?
- 怎样知道局域网路径是可写还是可读的?
- 定位多条表记录?
- 怎样判断MDI子窗口是否已经显示
- 如何用midiOutShortMsg,midiOutOpen使电脑发音?
- 调试器的用法, 谁有基础性的教材呢? 谢谢 --- [email protected]
- 在线等待:D5中的Cookie问题?
- 二个简单问题
- stringgrid的fixedrows如何改变字体?
- 如何在 在Acces数据库存储回车符,使用delphi读取出显示在label中,请问如何存储回车,如何 显示在label中
10*(x+y+z) = 20920;
得出X和Y的关系
8x + 5Y = 16508;
令X = 1时,你的穷举最大值不可能超过16500,穷举出了X、Y值你的Z值就好解决了。
2x+2y+2z=4184
3y+8z=228