码迷,mamicode.com
首页 > 其他好文 > 详细

HW4.11

时间:2016-08-14 13:09:05      阅读:136      评论:0      收藏:0      [点我收藏+]

标签:

技术分享

 

 1 public class Solution
 2 {
 3     public static void main(String[] args)
 4     {
 5         int count = 0;
 6 
 7         for(int i = 100; i <= 1000; i++)
 8         {
 9             if(i % 5 == 0 ^ i % 6 == 0)
10             {
11                 System.out.print(i + " ");
12                 count++;
13                 if(count == 10)
14                 {
15                     System.out.println();
16                     count = 0;
17                 }
18             }
19         }
20     }
21 }

 

HW4.11

标签:

原文地址:http://www.cnblogs.com/wood-python/p/5769969.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!