Hello!
The task requirements are not met. Could you please tell me what I got wrong with the "zero" requirement?
Thank you so much!
package com.codegym.task.task04.task0426;
/*
Labels and numbers
*/
import java.util.*;
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
Scanner console = new Scanner(System.in);
int num = console.nextInt();
if (num < 1 && (num % 2 == 0)) {
System.out.print("Negative even number");
} else if (num < 1 && (num % 2 != 0)) {
System.out.print("Negative odd number");
} else if (num > 1 && (num % 2 == 0)) {
System.out.print("Positive even number");
} else if (num > 1 && (num % 2 != 0)) {
System.out.print("Positive odd number");
} else {
System.out.print("Zero");
}
}
}