下面的程序是打印输出100~300之间的不能被3整除的数。请在每条横线处填写一条语句,使程序的功能完整。 注意:请勿改动main()主方法和其他已有的语句内容,仅在横线处填人适当的语句。 public class printNo3and

admin2009-01-15  21

问题 下面的程序是打印输出100~300之间的不能被3整除的数。请在每条横线处填写一条语句,使程序的功能完整。
   注意:请勿改动main()主方法和其他已有的语句内容,仅在横线处填人适当的语句。
       public class printNo3and5{
        void print()
         {
          int n  ;
          for(n=100 ;n<=300 ;n++){
            if(n%3==0)
          __________
             System.out.println(n);
             }
         }
        public static__________main(String args[])
       {
      printNo3and5 obj=new printN03and5();
          __________
      }
   }

选项

答案continue; void obj.print();

解析
转载请注明原文地址:https://kaotiyun.com/show/rhnp777K
0

最新回复(0)