We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Java
- Introduction
- Java If-Else
- Discussions
Java If-Else
Java If-Else
Sort by
recency
|
2049 Discussions
|
Please Login in order to post a comment
private static final Scanner scanner = new Scanner(System.in);
import java.io.; import java.math.; import java.security.; import java.text.; import java.util.; import java.util.concurrent.; import java.util.regex.*;
public class Solution {
}
String str = ""; if(N%2!=0 || (N>=6 && N<=20)){ str = "Weird"; }else{ str = "Not Weird"; } System.out.println(str);
For Java15 Platform
I wrote the code from scratch just to get more practice
import java.io.; import java.math.; import java.security.; import java.text.; import java.util.; import java.util.concurrent.; import java.util.regex.*;
public class Solution {
}