Skip to content

Instantly share code, notes, and snippets.

@incheon
Last active March 11, 2016 04:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save incheon/353f6f8309156bc4dd21 to your computer and use it in GitHub Desktop.
Save incheon/353f6f8309156bc4dd21 to your computer and use it in GitHub Desktop.
// Q1
public class Main {
public static void main(String[] args) {
for(int i=0;i<100;i=i+2){
System.out.println(i);
}
public static showEvens {
for(int i=0;i<100;i=i+2){
System.out.println(i);
}
}
public static void getEvens(int x){
for(int i=0;i<1000;i++){
System.out.println(i);
}
}
}
}
// // Q1
// public class q1 {
// public static void main(String[] args) {
// System.out.println("hello");
// }
// }
// // Q2
// public class q2 {
// public int THIS_YEAR = 2016;
// public int age;
// public String name;
// public static void main(String[] args) {
// Main m = new Main();
// m.age = 20;
// m.name = "Taro";
// }
// }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment