问题描述
for(int i = 0;i<4;i++) {//行数
for(int j = 0;i<3;j++) {//列数
ImageIcon icon = new ImageIcon("图片1_"+(i*3+j+1)+".gif");
cell[i*3+j] = new Cell(icon);
cell[i*3+j].setLocation(j*150+20, i*150+20);
this.add(cell[i*3+j]);
}
}
问题解答
回答1:第二个循环j打成i了,死循环
问题描述
for(int i = 0;i<4;i++) {//行数
for(int j = 0;i<3;j++) {//列数
ImageIcon icon = new ImageIcon("图片1_"+(i*3+j+1)+".gif");
cell[i*3+j] = new Cell(icon);
cell[i*3+j].setLocation(j*150+20, i*150+20);
this.add(cell[i*3+j]);
}
}
问题解答
回答1:第二个循环j打成i了,死循环相关文章:1. node.js - nodejs 执行shell脚本2. node.js - express路由问题3. node.js - app.get()不执行,麻烦谁指点以下。4. autodesk-forge - 以node.js 斷點續傳將模型上傳到Autodesk Forge,但api無回應?5. node.js - Node框架Egg.js和Express有何区别,哪个更适合新手学习。6. node.js - node 引入文件问题7. node.js - npm install 时报错tunneling socket could not be established求大神帮忙8. node.js - nodejs可以判断客户端的浏览器类型吗9. node.js - jsonp跨域为何get不到想要的内容10. 在node.js里面可以使用window对象的方法吗
网公网安备:皖ICP备2020019022号-8 Copyright ¢ 2020-2025 Powered by V1.8 All Rights Reserved 技术支持:乐呵呵网
声明:本站所有资源以学习为主