问题描述
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. upgrade - 在Ubuntu上升级Docker后出现的问题2. angular.js - 求解:angular ngModel.$render 值发生变化时,没有自动调用3. centos6.5加epel后,怎么无法搜到docker-io呢?4. ubuntu12.04 - docker pull ubuntu 总是出错5. docker - 如何用Doker搭建Ambari集群?6. docker - jenkins的时区设置问题7. docker - base image如何选择?8. angular.js - AngularJS的学习9. angular.js - angularjs 指令问题10. 如何不输出docker后台进程的日志到屏幕
网公网安备:皖ICP备2020019022号-8 Copyright ¢ 2020-2025 Powered by V1.8 All Rights Reserved 技术支持:乐呵呵网
声明:本站所有资源以学习为主