output 010123234545

来源:互联网 发布:apache ant 64位 编辑:程序博客网 时间:2024/06/02 21:37
/** * Created by Administrator on 2016/6/24 0024. */public class ja {    private static int count=0;    private static int total=19;    public static void main(String[] args)    {        for(int i=0;i<total;i++){            if(i==0){                System.out.println(i);            }else if(i==1){                System.out.println(i);            }else if(i%4==0 && i!=0 ){               for(int j=0;j<4;j++){                    System.out.println(j+count);                }                count=count+2;            }else if(i==total-2){               // System.out.println(i);                System.out.println(i-(total/4+1)*2+1);            } else if (i == total-1) {                System.out.println(i-(total/4+1)*2+1);            }else {                System.out.println("here is an error");            }            }    }}

0 0
原创粉丝点击