Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Problem: on_off
//'main' method must be in a class 'Rextester'. //Compiler version 1.8.0_111 import java.util.*; import java.lang.*; class Rextester { public static void main(String args[]) { for(int num=1 ; num<=100 ; num++) { if((num % 3)==0 && (num % 5) == 0) System.out.println("OnOff"); else if((num % 3) == 0) System.out.println("On"); else if((num % 5) == 0) System.out.println("Off"); else System.out.println(num); } } }
run
|
edit
|
history
|
help
0
Recursive list fields
메소드구현하기-해결
1.6
2darray
toStringMethodinJava
java polymorhism
right swastik
Test
mango
calc exp nha