A股上市公司传智教育(股票代码 003032)旗下技术交流社区北京昌平校区

© 乐享 中级黑马   /  2013-11-18 22:14  /  825 人查看  /  0 人回复  /   0 人收藏 转载请遵从CC协议 禁止商业使用本文

class Ceshi1
                {
                  public static void main(String[] args)
                                  {
                                  /*        for(int x=1 ;x<=100 ;x++)
                                          {
                                                  System.out.print(x+"\t");
                                                  }
                                           
                                  */               
                                 
                                 
                                  for (int x=1 ;x<=100 ;x++)
                                  {
                                          if(x<98)
                                          {
                                                  System.out.print(x+"\t");
                                                  }
                                          else if(x==98)
                                          {
                                                  System.out.print(x+"\t");break;
                                                  }
                                         
                                          }
                                 
                                  }
您需要登录后才可以回帖 登录 | 加入黑马